From f05712ec39543d1a974773ce16470170e82659fb Mon Sep 17 00:00:00 2001 From: "Builder.io" Date: Sun, 19 Oct 2025 05:09:50 +0000 Subject: [PATCH] Remove redirect to login on Admin when not authenticated; show inline access denied or loading cgen-1023d43dfd02419cbfc79d29929a6f5a --- client/pages/Admin.tsx | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/client/pages/Admin.tsx b/client/pages/Admin.tsx index 5cbdaafc..5ffab359 100644 --- a/client/pages/Admin.tsx +++ b/client/pages/Admin.tsx @@ -211,11 +211,7 @@ export default function Admin() { }, [loadOpportunityApplications]); useEffect(() => { - if (!loading) { - if (!user) { - navigate("/login", { replace: true }); - } - } + // Do not redirect unauthenticated users; show inline access UI instead }, [user, loading, navigate]); useEffect(() => { @@ -224,7 +220,7 @@ export default function Admin() { } }, [managedProfiles, selectedMemberId]); - if (loading || !user) { + if (loading) { return (