Fix regression in password settings: users have been unable to change their passwords since introduction of ChangePassword event (later StartChangePassword) November 5 in commit d6ddb84132

Logic was inversed; new password was only being saved if a plugin claimed the event; so when no auth plugin was present to take it, passwords never got saved.
This commit is contained in:
Brion Vibber 2009-12-01 15:44:07 -08:00
parent edb2578e93
commit 0c0f928459

View File

@ -170,7 +170,7 @@ class PasswordsettingsAction extends AccountSettingsAction
} }
$success = false; $success = false;
if(! Event::handle('StartChangePassword', array($user, $oldpassword, $newpassword))){ if(Event::handle('StartChangePassword', array($user, $oldpassword, $newpassword))){
//no handler changed the password, so change the password internally //no handler changed the password, so change the password internally
$original = clone($user); $original = clone($user);