Skip to content

Conversation

@jessevinco
Copy link

@jessevinco jessevinco commented Jul 5, 2022

mongoose.connect("mongodb://localhost:27017/userDB");

//Target the logout route, if not it won't work.//

app
.route("/logout")
.get((req, res) => {
req.logout(function(error) {
if (error) { return next(error); }
res.redirect("/");
});
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant