Skip to content

Commit

Permalink
fix: enable refresh token route
Browse files Browse the repository at this point in the history
  • Loading branch information
awinogrodzki committed Jun 15, 2024
1 parent f25d5a5 commit d081c22
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/next/middleware.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,9 @@ export async function authMiddleware(
debug('Handle request', {path: request.nextUrl.pathname});

if (
[options.loginPath, options.logoutPath].includes(request.nextUrl.pathname)
[options.loginPath, options.logoutPath, options.refreshTokenPath]
.filter(Boolean)
.includes(request.nextUrl.pathname)
) {
debug('Handle authentication API route');
return createAuthMiddlewareResponse(request, options);
Expand Down

0 comments on commit d081c22

Please sign in to comment.