Skip to content

Commit

Permalink
Merge branch 'github_fixes'
Browse files Browse the repository at this point in the history
  • Loading branch information
ciaranj committed Jun 19, 2012
2 parents 4f3666d + 56979c0 commit debc503
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 4 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -53,7 +53,9 @@ Run


Changelog Changelog
========= =========
* 0.5.2 * 0.5.3
Fix GitHub strategy to work with v3 of their API (older API versions no longer work!) (Dennis Reimann)
* 0.5.2
Allow multiple users per application in Oauth Provider (3 legged) (Evan Prodromou) Allow multiple users per application in Oauth Provider (3 legged) (Evan Prodromou)
Improved the behaviour of the OAuth Provider's Form/POST signing behaviours ( Evan Prodromou ) Improved the behaviour of the OAuth Provider's Form/POST signing behaviours ( Evan Prodromou )
Fix broken 3-legged OAuth provider support ( Jason Chu ) Fix broken 3-legged OAuth provider support ( Jason Chu )
Expand Down
4 changes: 2 additions & 2 deletions lib/auth.strategies/github.js
Original file line number Original file line Diff line number Diff line change
Expand Up @@ -55,12 +55,12 @@ module.exports= function(options, server) {
else { else {
request.session["access_token"]= access_token; request.session["access_token"]= access_token;
if( refresh_token ) request.session["refresh_token"]= refresh_token; if( refresh_token ) request.session["refresh_token"]= refresh_token;
my._oAuth.getProtectedResource("https://github.com/api/v2/json/user/show", request.session["access_token"], function (error, data, response) { my._oAuth.getProtectedResource("https://api.github.com/user", request.session["access_token"], function (error, data, response) {
if( error ) { if( error ) {
request.getAuthDetails()['github_login_attempt_failed'] = true; request.getAuthDetails()['github_login_attempt_failed'] = true;
self.fail(callback); self.fail(callback);
}else { }else {
self.success(JSON.parse(data).user, callback) self.success(JSON.parse(data), callback)
} }
}) })
} }
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Original file line Diff line number Diff line change
@@ -1,7 +1,7 @@
{ {
"name" : "connect-auth", "name" : "connect-auth",
"description" : "Middleware for Connect (node.js) for handling your authentication needs.", "description" : "Middleware for Connect (node.js) for handling your authentication needs.",
"version" : "0.5.2", "version" : "0.5.3",
"author" : "Ciaran Jessup <ciaranj@gmail.com>", "author" : "Ciaran Jessup <ciaranj@gmail.com>",
"engines" : {"node" : ">=0.6.0"}, "engines" : {"node" : ">=0.6.0"},
"main" : "lib/index.js", "main" : "lib/index.js",
Expand Down

0 comments on commit debc503

Please sign in to comment.