user.setPassword is not a function - passport local mongoose
问题 I am implementing a reset password feature on for the users of my website. However, it seems to throw this error when the user confirms new password at the reset.ejs page. The following steps are being performed correctly: Token sent on mail When clicked on token, new password page opens When user enters new password and confirm new password and hits the button to save the new password, the function in users.js user.setPassword does not work as the error is mentioned below. It is a built in