Skip to content

Commit

Permalink
Allow oauth-authorized
Browse files Browse the repository at this point in the history
  • Loading branch information
dyakovri committed Apr 7, 2024
1 parent 7c17a3d commit c5c0ba1
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/router/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,12 @@ router.beforeEach(async to => {
return { path: '/auth' };
}
// TODO: Убрать костыль с to.path
if (isAuth && token && to.path !== '/auth/reset/email') {
if (
isAuth &&
token &&
to.path !== '/auth/reset/email' &&
!to.path.startsWith('/auth/oauth-authorized')
) {
return { path: '/profile' };
}
});
Expand Down

0 comments on commit c5c0ba1

Please sign in to comment.