Skip to content

Commit 3228b5e

Browse files
committed
Allow null body
See oauthjs#69
1 parent 22c670f commit 3228b5e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/authorise.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ function Authorise (config, req, next) {
5656
function getBearerToken (done) {
5757
var headerToken = this.req.get('Authorization'),
5858
getToken = this.req.query.access_token,
59-
postToken = this.req.body && this.req.body.access_token;
59+
postToken = this.req.body ? this.req.body.access_token : undefined;
6060

6161
// Check exactly one method was used
6262
var methodsUsed = (headerToken !== undefined) + (getToken !== undefined) +

0 commit comments

Comments
 (0)