fix: always call fetchMe() on mount — loading:true blocked initial auth check
This commit is contained in:
parent
15bf9d3935
commit
dc1add0b1b
1 changed files with 1 additions and 1 deletions
|
|
@ -24,7 +24,7 @@ function AuthGate({ children }: { children: React.ReactNode }) {
|
|||
const acquire = async () => {
|
||||
// Dev mode: skip MSAL, just call /auth/me directly
|
||||
if (import.meta.env.DEV || accounts.length === 0) {
|
||||
if (!user && !loading) fetchMe()
|
||||
if (!user) fetchMe()
|
||||
return
|
||||
}
|
||||
try {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue