We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e676a18 commit 203d9e4Copy full SHA for 203d9e4
apps/studio/components/interfaces/SignIn/SignInForm.tsx
@@ -52,8 +52,9 @@ const SignInForm = () => {
52
53
toast.success(`Signed in successfully!`, { id: toastId })
54
await queryClient.resetQueries()
55
-
56
- router.push(getReturnToPath())
+ const returnTo = getReturnToPath()
+ // since we're already on the /sign-in page, prevent redirect loops
57
+ router.push(returnTo === '/sign-in' ? '/projects' : returnTo)
58
} catch (error) {
59
toast.error((error as AuthError).message, { id: toastId })
60
}
0 commit comments