fix(webapp): localize footer/menu and harden auth routes
This commit is contained in:
@@ -1,11 +1,13 @@
|
||||
export default defineNuxtRouteMiddleware(async (to) => {
|
||||
const basePath = stripLocalePrefix(to.path, ['ru', 'en'])
|
||||
|
||||
// Skip auth routes handled by @logto/nuxt
|
||||
if (to.path === '/sign-in' || to.path === '/sign-out' || to.path === '/callback') {
|
||||
if (basePath === '/sign-in' || basePath === '/sign-out' || basePath === '/callback') {
|
||||
return
|
||||
}
|
||||
|
||||
// Skip public auth paths
|
||||
if (to.path.startsWith('/auth/')) {
|
||||
if (basePath.startsWith('/auth/')) {
|
||||
return
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user