fix chain modal

This commit is contained in:
xuyue committed 2026-04-30 09:42:38 -06:00
1 parent dd249c8753
commit 375a78b852
6 files changed
+35 -67

No files matched your search

+2 -4
View File
@@ -68,12 +68,10 @@ export const router = createRouter({
routes,
})
router.beforeEach((to, from, next) => {
router.beforeEach((to) => {
const isLoggedIn = localStorage.getItem(STORAGE_KEY.LOGIN) === "true"
if (to.meta.auth && !isLoggedIn) {
loginModal.value = true
next(false)
} else {
next()
return false
}
})