Skip to content

Commit

Permalink
Fix for 'this.redirect is missing' in openid
Browse files Browse the repository at this point in the history
  • Loading branch information
cortfr committed May 31, 2012
1 parent ae47e87 commit 5375cf4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion lib/modules/openid.js
Expand Up @@ -45,6 +45,7 @@ everyModule.submodule('openid')
.accepts('res')
.promises(null)
.sendToAuthenticationUri(function(req,res) {
var that = this;

// Automatic hostname detection + assignment
if (!this._myHostname || this._alwaysDetectHostname) {
Expand All @@ -53,7 +54,7 @@ everyModule.submodule('openid')

this.relyingParty.authenticate(req.query[this.openidURLField()], false, function(err,authenticationUrl){
if(err) return p.fail(err);
this.redirect(res, authenticationUrl);
that.redirect(res, authenticationUrl);
});
})
.getSession( function(req) {
Expand Down

0 comments on commit 5375cf4

Please sign in to comment.