check for form.password in the off chance that a user is logged in and the server switches the authentication method from basic_auth to openid.
This commit is contained in:
parent
402f436011
commit
5a6e4e1307
@ -444,7 +444,7 @@ def change_email(request):
|
|||||||
_('Sorry, a user with that email address'
|
_('Sorry, a user with that email address'
|
||||||
' already exists.'))
|
' already exists.'))
|
||||||
|
|
||||||
if user.pw_hash and not auth.check_password(
|
if form.password and user.pw_hash and not auth.check_password(
|
||||||
form.password.data, user.pw_hash):
|
form.password.data, user.pw_hash):
|
||||||
form.password.errors.append(
|
form.password.errors.append(
|
||||||
_('Wrong password'))
|
_('Wrong password'))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user