feat: add login redirect to the page which initiated auth

This commit is contained in:
Kentai Radiquum 2024-08-04 14:33:22 +05:00
parent d28011b4fb
commit 3378d5b99e
Signed by: Radiquum
GPG key ID: 858E8EE696525EED
7 changed files with 12 additions and 14 deletions

View file

@ -71,7 +71,7 @@ export function FavoritesPage() {
useEffect(() => {
if (authState === "finished" && !token) {
router.push("/login");
router.push("/login?redirect=/favorites");
}
}, [authState, token]);