This commit is contained in:
wayanrivan
2026-07-02 15:20:41 +07:00
parent 8ca596af86
commit ea1a678a25
6 changed files with 171 additions and 101 deletions

View File

@ -8,6 +8,8 @@ const RequireAuth = () => {
const { auth, loading } = useAuthContext();
const location = useLocation();
// console.log('RequireAuth render: loading =', loading, ' auth =', auth);
if (loading) {
return <ScreenLoader />;
}
@ -15,4 +17,4 @@ const RequireAuth = () => {
return auth ? <Outlet /> : <Navigate to="/auth/login" replace />;
};
export { RequireAuth };
export { RequireAuth };