Browse files

Merge branch 'github_fixes'

  • Loading branch information...
2 parents 4f3666d + 56979c0 commit debc503eeddf90f698052b6de0edd4d959d6eade @ciaranj committed Jun 19, 2012
Showing with 6 additions and 4 deletions.
  1. +3 −1 README.md
  2. +2 −2 lib/auth.strategies/github.js
  3. +1 −1 package.json
View
4 README.md
@@ -53,7 +53,9 @@ Run
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)
Improved the behaviour of the OAuth Provider's Form/POST signing behaviours ( Evan Prodromou )
Fix broken 3-legged OAuth provider support ( Jason Chu )
View
4 lib/auth.strategies/github.js
@@ -55,12 +55,12 @@ module.exports= function(options, server) {
else {
request.session["access_token"]= access_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 ) {
request.getAuthDetails()['github_login_attempt_failed'] = true;
self.fail(callback);
}else {
- self.success(JSON.parse(data).user, callback)
+ self.success(JSON.parse(data), callback)
}
})
}
View
2 package.json
@@ -1,7 +1,7 @@
{
"name" : "connect-auth",
"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>",
"engines" : {"node" : ">=0.6.0"},
"main" : "lib/index.js",

0 comments on commit debc503

Please sign in to comment.