fix: Login flow - remove reload, sync auth state reactively
This commit is contained in:
@@ -37,11 +37,8 @@ export function Login() {
|
||||
window.WNW_CONFIG.currentUser = data.user;
|
||||
window.WNW_CONFIG.nonce = data.nonce;
|
||||
|
||||
// Redirect to dashboard
|
||||
// Redirect to dashboard (no reload needed, auth state is updated)
|
||||
navigate('/dashboard');
|
||||
|
||||
// Reload to ensure all auth state is fresh
|
||||
window.location.reload();
|
||||
} else {
|
||||
setError(data.message || __('Invalid username or password'));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user