1
0
mirror of https://github.com/node-red/node-red.git synced 2023-10-10 13:36:53 +02:00

Handle non-error responses from token function

This commit is contained in:
Nick O'Leary 2022-01-12 13:48:06 +00:00
parent 7732d52583
commit ea20342d76
No known key found for this signature in database
GPG Key ID: 4F2157149161A6C9

View File

@ -163,7 +163,9 @@ TokensStrategy.prototype.authenticate = function(req) {
authenticateUserToken(req).then(user => {
this.success(user,{scope:user.permissions});
}).catch(err => {
log.trace("token authentication failure: "+err.stack)
if (err) {
log.trace("token authentication failure: "+err.stack?err.stack:err)
}
this.fail(401);
});
}