Added missing tokenSecret when new twitter account is created
This commit is contained in:
@@ -71,7 +71,7 @@ passport.use(new TwitterStrategy(config.twitter, function(accessToken, tokenSecr
|
|||||||
if (existingUser) return done(null, existingUser);
|
if (existingUser) return done(null, existingUser);
|
||||||
var user = new User();
|
var user = new User();
|
||||||
user.twitter = profile.id;
|
user.twitter = profile.id;
|
||||||
user.tokens.push({ kind: 'twitter', token: accessToken });
|
user.tokens.push({ kind: 'twitter', token: accessToken, tokenSecret: tokenSecret });
|
||||||
user.profile.name = profile.displayName;
|
user.profile.name = profile.displayName;
|
||||||
user.profile.location = profile._json.location;
|
user.profile.location = profile._json.location;
|
||||||
user.profile.picture = profile._json.profile_image_url;
|
user.profile.picture = profile._json.profile_image_url;
|
||||||
|
Reference in New Issue
Block a user