Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- module.exports = function (req, res, next) {
- // Initialize Passport
- passport.initialize()(req, res, function () {
- // Use the built-in sessions
- passport.session()(req, res, function () {
- // Make the user available throughout the frontend
- res.locals.user = req.user;
- next();
- });
- });
- };
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement