Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change password - verifying old password #127

Closed
gentlee opened this issue Mar 16, 2016 · 3 comments
Closed

Change password - verifying old password #127

gentlee opened this issue Mar 16, 2016 · 3 comments
Labels

Comments

@gentlee
Copy link
Contributor

gentlee commented Mar 16, 2016

User needs to enter old and new password to change it, so how should i verify old password? Method setPassword doesn't have oldPassword parameter.

@PunkHaz4rd
Copy link

+1
This is critical

@mrsteele
Copy link

I wanted to +1 this as well.

I think the closest thing to get this to work right is to do the schema.methods.authenticate and if that passes, run the schema.methods.setPassword, however the problem is that the authenticate method runs through an entire process of logging in, which would be overkill for this feature.

saintedlama added a commit that referenced this issue Aug 8, 2017
@saintedlama
Copy link
Owner

Newest npm version added a changePassword functionality. See api doc in the README

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

4 participants