I am having trouble getting my system to log out with PassportJS. It seems the logout route is being called, but its not removing the session. I want it to return 401, if th
Ran into the same issue. Using req.session.destroy(); instead of req.logout(); works, but I don't know if this is the best practice.
req.session.destroy();
req.logout();