From 2960d1ffd8a75fee216548e7e1bfd131c3884539 Mon Sep 17 00:00:00 2001 From: Spythere Date: Mon, 30 Jan 2023 17:51:59 +0100 Subject: [PATCH] fix: auth redirect --- src/App.vue | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/App.vue b/src/App.vue index 27cfe53..65a3ae4 100644 --- a/src/App.vue +++ b/src/App.vue @@ -21,7 +21,7 @@ export default defineComponent({ const router = useRouter(); router.beforeEach(async (to, from, next) => { - if (store.authState != AuthState.AUTHORIZED && to.path != '/login') return next({ path: '/login' }); + if (store.authState == AuthState.AUTHORIZED && to.path == '/login') return next({ path: '/' }); return next(); });