passaporte.authenticate dentro de um controlador
//DECLARE DE REQUIRES
exports.createUser = (req, res, next) => {
passport.authenticate('local-signup', {
successRedirect : '/all',
failureRedirect : '/signup',
failureFlash : true
})(req, res, next); // -> IMPORTANT
};
Zarden