Skip to content

Conversation

@bentedder
Copy link
Contributor

@bentedder bentedder commented May 26, 2017

This makes the passwordCurrent attribute optional in the interface. Check out the problems when trying to reset a password when the user is not already authenticated or has forgotten their password. Setting this property to null before sending it fixes the problem, so just having a model that doesn't require it should prevent the workaround.

#205 (comment)

Here the property is already been checked against "null", meaning if it's a required string this line of code will never be reached: https://github.com/neroniaky/angular2-token/blob/master/src/angular2-token.service.ts#L270

@neroniaky
Copy link
Owner

Perfect! Thanks @bentedder for catching this error!

@neroniaky neroniaky merged commit 3531be9 into neroniaky:master May 31, 2017
@MuhammadIrtazaSafi
Copy link

Please push these changes to npm.

neroniaky added a commit that referenced this pull request Jun 19, 2022
make passwordCurrent an optional param
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.

3 participants