[V0.1 WORKING] Added chat, profile, & calendar screen implementations.
This commit is contained in:
@@ -174,7 +174,7 @@ export const AuthProvider: React.FC<AuthProviderProps> = ({ children }) => {
|
||||
setAuthToken(null);
|
||||
delete apiClient.defaults.headers.common['Authorization'];
|
||||
await deleteToken(); // Use helper
|
||||
// Optional backend logout call
|
||||
await apiClient.post("/auth/logout");
|
||||
}, []);
|
||||
|
||||
const contextValue = useMemo(() => ({
|
||||
@@ -192,7 +192,6 @@ export const AuthProvider: React.FC<AuthProviderProps> = ({ children }) => {
|
||||
);
|
||||
};
|
||||
|
||||
// --- useAuth and AuthLoadingScreen remain the same ---
|
||||
export const useAuth = () => {
|
||||
const context = useContext(AuthContext);
|
||||
if (!context) {
|
||||
|
||||
Reference in New Issue
Block a user