Skip to content

Commit

Permalink
Fix route visualization in auth
Browse files Browse the repository at this point in the history
  • Loading branch information
kartikmehta8 committed Nov 3, 2024
1 parent d8909b1 commit 224487d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion blog/2024-11-04-jwt-authentication-in-orion.md
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,7 @@ class AuthMiddleware extends IMiddleware {
handle(req, res, next) {

// Check if route is protected, if not, skip authentication and it does not starts with /visualize/
const routeStartsWithVisualize = req.originalUrl.startsWith('/visualize/');
const routeStartsWithVisualize = req.originalUrl.startsWith('/visualize');
if (req.originalUrl === settings.GENERAL.API_PREFIX + '/login' || req.originalUrl === settings.GENERAL.API_PREFIX + '/signup' || routeStartsWithVisualize ) {
return next();
}
Expand Down

0 comments on commit 224487d

Please sign in to comment.