]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
ROLLBACK if query failed in email settings savePreferences
authorMikael Nordfeldth <mmn@hethane.se>
Thu, 19 Feb 2015 16:42:47 +0000 (17:42 +0100)
committerMikael Nordfeldth <mmn@hethane.se>
Thu, 19 Feb 2015 16:43:08 +0000 (17:43 +0100)
actions/emailsettings.php

index 0c2033d821d0587a0bcbf5aeb974d17ad3024ebd..96ada2c826e49058b81be6db6d9d4b0d97ad8542 100644 (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.'));
             }