]> git.mxchange.org Git - quix0rs-gnu-social.git/commitdiff
Check profile->update() result against false exactly; we may legitimately get 0 back...
authorBrion Vibber <brion@pobox.com>
Thu, 19 Nov 2009 01:36:55 +0000 (17:36 -0800)
committerBrion Vibber <brion@pobox.com>
Thu, 19 Nov 2009 01:36:55 +0000 (17:36 -0800)
Caused failures saving profile settings with Geonames plugin enabled; the lat/lon/id fields would get re-set with freshly looked up values which no longer matched the previous values as far as the data object could tell, but which saved as the same ol' numbers.

actions/profilesettings.php

index 0a0cc59973a3709c272a93e74bf1e9176f46c5d5..359664096ee8a3a715ae02b703902922bf617790 100644 (file)
@@ -323,7 +323,7 @@ class ProfilesettingsAction extends AccountSettingsAction
 
             $result = $profile->update($orig_profile);
 
-            if (!$result) {
+            if ($result === false) {
                 common_log_db_error($profile, 'UPDATE', __FILE__);
                 $this->serverError(_('Couldn\'t save profile.'));
                 return;