From aa541fcc5ce79849dc2a6f91b80f54acf145a9ca Mon Sep 17 00:00:00 2001 From: Matt Date: Thu, 7 Aug 2025 14:31:46 +0200 Subject: [PATCH] fix: improve login redirect reliability by using window.location for navigation --- pages/login.vue | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pages/login.vue b/pages/login.vue index 6e22048..7c40663 100644 --- a/pages/login.vue +++ b/pages/login.vue @@ -186,9 +186,12 @@ const handleLogin = async () => { }); if (result.success) { - // Handle redirect from the component + // Handle redirect from the component using window.location for reliability console.log('🔄 Login successful, redirecting to:', result.redirectTo); - await navigateTo(result.redirectTo || '/dashboard'); + const redirectUrl = result.redirectTo || '/dashboard'; + + // Use window.location for a reliable redirect + window.location.href = redirectUrl; } else { loginError.value = result.error || 'Login failed. Please check your credentials and try again.'; }