mirror of
https://github.com/taobataoma/meanTorrent.git
synced 2026-07-19 22:20:50 +02:00
added permission request for email
the application will trigger an error is this is not added here, since you won't have access to user's email in passport's facebook strategy.
This commit is contained in:
@@ -14,6 +14,7 @@ module.exports = function(app) {
|
||||
|
||||
// Setting the facebook oauth routes
|
||||
app.get('/auth/facebook', passport.authenticate('facebook', {
|
||||
scope: ['email'],
|
||||
failureRedirect: '/#!/signin'
|
||||
}), users.signin);
|
||||
app.get('/auth/facebook/callback', passport.authenticate('facebook', {
|
||||
@@ -50,4 +51,4 @@ module.exports = function(app) {
|
||||
|
||||
// Finish by binding the user middleware
|
||||
app.param('userId', users.userByID);
|
||||
};
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user