Closed sylido closed 9 years ago
Seems like it is an issue for here. I've located the problematic code in login_buttons.js
starting on line 160. The function validatePassword
takes in the two arguments and checks the password
length, after that it checks for passwordAgain
which in this case would be `(the empty string) and it will result in the function returning
true. I guess this function handles
changePasswordand
signupas well, where you don't have
passwordAgain, you just pass in
password` for a length validation.
Nice work finding where the issue was! However, I think the better approach to fixing this is to modify the Accounts._loginButtons.validatePassword
function to check the existance of passwordAgain
properly.
It should work now!
Hey man thanks, yeah I was just trying to get your attention so I applied this quick fix :) thank you for fixing it
Also noticed you are doing password != passwordAgain
why not password !== passwordAgain
?
Well, I don't see the advantage of using !==
in this case. The only difference is that 1234567 !== '1234567'
but 1234567 == '1234567'
(==
and !=
type cast), and in this case we know for sure both vars will be a string. And even if they weren't, it doesn't really matter.
Not sure how much control over this accounts-ui-bootstrap-3 has, maybe it's the accounts package that is messing up ?