This commit is contained in:
@@ -6,6 +6,7 @@ export default defineNuxtRouteMiddleware(async (to, from) => {
|
||||
if (!me.value) {
|
||||
try {
|
||||
setMe(await chadApi('/me', { method: 'GET' }))
|
||||
return navigateTo({ name: 'Index' })
|
||||
}
|
||||
catch {
|
||||
if (to.meta.auth !== 'guest') {
|
||||
|
||||
Reference in New Issue
Block a user