ROLLBACK if query failed in email settings savePreferences

This commit is contained in:
Mikael Nordfeldth 2015-02-19 17:42:47 +01:00
parent 0acf3e0e30
commit 042cb1604a

View File

@ -340,6 +340,7 @@ class EmailsettingsAction extends SettingsAction
if ($result === false) {
common_log_db_error($user, 'UPDATE', __FILE__);
$user->query('ROLLBACK');
// TRANS: Server error thrown on database error updating e-mail preferences.
$this->serverError(_('Could not update user.'));
}