Unless is not working
See original GitHub issueI have a route which is /authenticate
I have defined it as
app.use(expressjwt({secret: config.sessionSecret}).unless({path: ['/authenticate']}));
But when I do a post to /authenticate
path it give me an error saying
UnauthorizedError: No authorization token was found
...
/authenticate
is working without express-jwt
Issue Analytics
- State:
- Created 7 years ago
- Comments:9 (2 by maintainers)
Top Results From Across the Web
Ruby on Rails 'unless' not working - Stack Overflow
The problem in that the headers are showing when there is no tests, e.g. the completed tests header is showing when there are...
Read more >#Unless is not working - Meteor forums
Hi,. As you can see I have no customers in my collection. So why does this code not work? Template.OEMPartner.helpers({ customers() { return ......
Read more >puppet logical conditions- "onlyif" and "unless" not working
I tried adding conditions using onlyif and unless which are commented in the following code but none of them seem to be working...
Read more >Unless - Grammar - Cambridge Dictionary
We use the conjunction unless to mean 'except if'. The clause which follows unless is a subordinate clause (sc): it needs a main...
Read more >"unless" statement inside of "if" statement not working - Ruby
if hungry != true, the unless statement SHOULD run the else statement which puts “time to eat!” and then there is an “end”...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
/authenticate
will redirect to/authenticate/
try add slash to end of path
change to
app.use(expressjwt({secret: config.sessionSecret}).unless({path: ['/authenticate/']}));
I had same problem. Try setting strict: false in your configuration object @iamchathu