Rename var

This commit is contained in:
Michael Fatemi 2021-04-10 17:51:02 -04:00
parent d1a263ce38
commit 45d641addb
2 changed files with 5 additions and 5 deletions

View File

@ -10,10 +10,10 @@ export type AuthState = {
refreshAuthState: (() => void) | null; refreshAuthState: (() => void) | null;
}; };
const Authentication = createContext<AuthState>({ const AuthenticationContext = createContext<AuthState>({
isLoggedIn: false, isLoggedIn: false,
user: null, user: null,
refreshAuthState: null, refreshAuthState: null,
}); });
export default Authentication; export default AuthenticationContext;

View File

@ -1,6 +1,6 @@
import { useCallback, useEffect, useState } from 'react'; import { useCallback, useEffect, useState } from 'react';
import { getMe } from '../api/api'; import { getMe } from '../api/api';
import Authentication, { AuthState } from './AuthenticationContext'; import AuthenticationContext, { AuthState } from './AuthenticationContext';
export default function AuthenticationWrapper({ export default function AuthenticationWrapper({
children, children,
@ -37,9 +37,9 @@ export default function AuthenticationWrapper({
return null; return null;
} else { } else {
return ( return (
<Authentication.Provider value={authState}> <AuthenticationContext.Provider value={authState}>
{children} {children}
</Authentication.Provider> </AuthenticationContext.Provider>
); );
} }
} }