You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
router.route('/auth/facebook')
.post(passport.authenticate('facebook-token', {session: false}), function(req, res, next) {
if (!req.user) {
return res.send(401, 'User Not Authenticated');
}
// prepare token for API
req.auth = {
id: req.user.id
};
next();
}, generateToken, sendToken);
I mean third argument of method post (function(req,res,next)), and of course render response in this function. And avoid adding fourth and fifth argument (generateToken, sendToken) ?
The text was updated successfully, but these errors were encountered:
I mean third argument of method post (function(req,res,next)), and of course render response in this function. And avoid adding fourth and fifth argument (generateToken, sendToken) ?
The text was updated successfully, but these errors were encountered: