fix: follow the happy path
This commit is contained in:
parent
20660564c1
commit
34182b8bbb
@ -21,11 +21,11 @@ export function useRedirectToLastVisited() {
|
|||||||
|
|
||||||
function redirectIfSaved() {
|
function redirectIfSaved() {
|
||||||
const lastRoute = getLastVisitedRoute()
|
const lastRoute = getLastVisitedRoute()
|
||||||
if (lastRoute) {
|
if (!lastRoute) {
|
||||||
return router.push(lastRoute)
|
return router.push({name: 'home'})
|
||||||
}
|
}
|
||||||
|
|
||||||
return router.push({name: 'home'})
|
return router.push(lastRoute)
|
||||||
}
|
}
|
||||||
|
|
||||||
return {
|
return {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user