how to check user is logged in or not in passport js node code example
Example: passport middleware check if authenticated
//just for me lol
app.post("/login", passport.authenticate("local", {
successRedirect: "/secret",
failureRedirect: "/login"
}), function(req,res){
//don't need to add anything
});