Skip to content

Commit

Permalink
fix(auth/middleware): Remove infinite redirect
Browse files Browse the repository at this point in the history
  • Loading branch information
wale committed Mar 26, 2024
1 parent 2289661 commit e112fa7
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion middleware/auth.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,5 +8,4 @@ export default defineNuxtRouteMiddleware((to) => {
if (to.fullPath === "/login" && user.value.id) return navigateTo("/");

if (!user.value.id) return navigateTo("/login");
else return navigateTo(to.fullPath);
});

0 comments on commit e112fa7

Please sign in to comment.