Permalink
Browse files

less checks

  • Loading branch information...
1 parent 4512cf5 commit 3501196327ed1b045aba34788d083dfbdb245d79 @simonmcmanus simonmcmanus committed Nov 29, 2012
Showing with 1 addition and 2 deletions.
  1. +1 −2 server.js
View
@@ -208,15 +208,14 @@ self.fetch = function(url, oauthToken, oauthTokenSecret, callback) {
// Used to connect using oauth.
self.oauthConnect = function(req, res, next) {
var referer = req.header('Referer');
- if(referer && req.session){
+ if(referer){
req.session.originalUrl = referer; // stored so we can return them to here later.
}
self.consumer.getOAuthRequestToken(function(error, oauthToken, oauthTokenSecret, results){
if (error) {
res.send("Error getting OAuth request token : ", 500);
console.log('oAuth error: '+ error);
} else {
- console.log(oauthToken);
req.session.oauthRequestToken = oauthToken; // we will need these values in the oauthCallback so store them on the session.
req.session.oauthRequestTokenSecret = oauthTokenSecret;

0 comments on commit 3501196

Please sign in to comment.