fix: default to local timeline when logged out (#855)
parent
b5e14810af
commit
697a88ac3d
|
@ -22,7 +22,7 @@ const reload = async () => {
|
||||||
try {
|
try {
|
||||||
if (!masto.loggedIn.value)
|
if (!masto.loggedIn.value)
|
||||||
await masto.loginTo(currentUser.value)
|
await masto.loginTo(currentUser.value)
|
||||||
clearError({ redirect: currentUser.value ? '/home' : `/${currentServer.value}/public` })
|
clearError({ redirect: currentUser.value ? '/home' : `/${currentServer.value}/public/local` })
|
||||||
}
|
}
|
||||||
catch {
|
catch {
|
||||||
state.value = 'error'
|
state.value = 'error'
|
||||||
|
|
|
@ -6,7 +6,7 @@ export default defineNuxtRouteMiddleware((to) => {
|
||||||
|
|
||||||
onMastoInit(() => {
|
onMastoInit(() => {
|
||||||
if (!currentUser.value)
|
if (!currentUser.value)
|
||||||
return navigateTo(`/${currentServer.value}/public`)
|
return navigateTo(`/${currentServer.value}/public/local`)
|
||||||
if (to.path === '/')
|
if (to.path === '/')
|
||||||
return navigateTo('/home')
|
return navigateTo('/home')
|
||||||
})
|
})
|
||||||
|
|
Loading…
Reference in New Issue