Fix AuthContext issue after refactoring

This commit is contained in:
2026-03-14 23:22:28 -03:00
parent 6898297935
commit 47f2f4c13f
2 changed files with 3 additions and 10 deletions
+1 -10
View File
@@ -1,10 +1 @@
import { useContext } from 'react';
import { AuthContext } from './AuthContextType';
export const useAuth = () => {
const context = useContext(AuthContext);
if (!context) {
throw new Error('useAuth must be used within an AuthProvider');
}
return context;
};
export { useAuth } from './AuthContext';