fix: redirect issues for authorized users (#374)

This commit is contained in:
Hayden 2023-03-25 11:07:22 -08:00 committed by GitHub
parent 0264bfb8c1
commit 8c57ff841e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 5 additions and 6 deletions

View file

@ -8,6 +8,9 @@
});
const ctx = useAuthContext();
if (ctx.isAuthorized()) {
navigateTo("/home");
}
const api = usePublicApi();
const toast = useNotifier();
@ -29,10 +32,6 @@
}
});
if (!ctx.isAuthorized()) {
navigateTo("/home");
}
const route = useRoute();
const router = useRouter();