passport-linkedin-oauth2
Advanced tools
Comparing version 1.6.0 to 1.6.1
@@ -68,3 +68,3 @@ var util = require('util'), | ||
const profileUrl = getProfileUrl(this.scope, this.profileFields, ['public-profile-url']); | ||
this._oauth2.get(profileUrl, accessToken, (err, body, res) => { | ||
return this._oauth2.get(profileUrl, accessToken, (err, body, res) => { | ||
if(err) { | ||
@@ -71,0 +71,0 @@ return done(new InternalOAuthError('failed to fetch user profile', err)); |
{ | ||
"name": "passport-linkedin-oauth2", | ||
"version": "1.6.0", | ||
"version": "1.6.1", | ||
"description": "Passport for LinkedIn Oauth2", | ||
@@ -5,0 +5,0 @@ "main": "./lib", |
@@ -367,3 +367,15 @@ var assert = require("assert"); | ||
// See: https://github.com/auth0/passport-linkedin-oauth2/pull/70 | ||
it('it calls callback only once when get profile fails the first time', function(done) { | ||
const { strategy, getStub } = createStrategy(); | ||
getStub.onFirstCall().callsArgWith(2, new Error('test')); | ||
getStub.onSecondCall().callsArgWith(2, null, jsonBody); | ||
strategy.userProfile('token', (err, profile) => { | ||
done(); | ||
}); | ||
}); | ||
}); | ||
}); |
New author
Supply chain riskA new npm collaborator published a version of the package for the first time. New collaborators are usually benign additions to a project, but do indicate a change to the security surface area of a package.
Found 1 instance in 1 package
28042
581
1