mirror of
https://github.com/myfatemi04/wheelshare-frontend.git
synced 2025-04-21 11:20:17 -04:00
Rename var
This commit is contained in:
parent
d1a263ce38
commit
45d641addb
|
@ -10,10 +10,10 @@ export type AuthState = {
|
|||
refreshAuthState: (() => void) | null;
|
||||
};
|
||||
|
||||
const Authentication = createContext<AuthState>({
|
||||
const AuthenticationContext = createContext<AuthState>({
|
||||
isLoggedIn: false,
|
||||
user: null,
|
||||
refreshAuthState: null,
|
||||
});
|
||||
|
||||
export default Authentication;
|
||||
export default AuthenticationContext;
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
import { useCallback, useEffect, useState } from 'react';
|
||||
import { getMe } from '../api/api';
|
||||
import Authentication, { AuthState } from './AuthenticationContext';
|
||||
import AuthenticationContext, { AuthState } from './AuthenticationContext';
|
||||
|
||||
export default function AuthenticationWrapper({
|
||||
children,
|
||||
|
@ -37,9 +37,9 @@ export default function AuthenticationWrapper({
|
|||
return null;
|
||||
} else {
|
||||
return (
|
||||
<Authentication.Provider value={authState}>
|
||||
<AuthenticationContext.Provider value={authState}>
|
||||
{children}
|
||||
</Authentication.Provider>
|
||||
</AuthenticationContext.Provider>
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user