summaryrefslogtreecommitdiff
path: root/actions/profilesettings.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@prodromou.name>2008-06-18 23:32:12 -0400
committerEvan Prodromou <evan@prodromou.name>2008-06-18 23:32:12 -0400
commit4aedce6864eb27a0c37b3dcae22fee0aa16ae537 (patch)
treef17f65eff878beb73c71e319945babdbed22546d /actions/profilesettings.php
parent0620e9f6680b45978fb49f31b93d70bb519ebfd5 (diff)
do some commits
darcs-hash:20080619033212-84dde-2f7227fe16c7015b03121424520ebd74d4b96762.gz
Diffstat (limited to 'actions/profilesettings.php')
-rw-r--r--actions/profilesettings.php10
1 files changed, 8 insertions, 2 deletions
diff --git a/actions/profilesettings.php b/actions/profilesettings.php
index 44abb8e99..159dab18a 100644
--- a/actions/profilesettings.php
+++ b/actions/profilesettings.php
@@ -122,7 +122,9 @@ class ProfilesettingsAction extends SettingsAction {
common_debug('Updating, nickname ="'.$user->nickname.'" and email ="'.$user->email.'"');
common_debug('Original, nickname ="'.$original->nickname.'" and email ="'.$original->email.'"');
- if (FALSE === $user->update($original)) {
+ $result = $user->update($original);
+
+ if (!$result) {
common_server_error(_t('Couldnt update user.'));
return;
}
@@ -138,12 +140,16 @@ class ProfilesettingsAction extends SettingsAction {
$profile->location = $location;
$profile->profileurl = common_profile_url($nickname);
- if (FALSE === $profile->update($orig_profile)) {
+ $result = $profile->update($orig_profile);
+
+ if (!$result) {
common_server_error(_t('Couldnt save profile.'));
return;
}
common_broadcast_profile($profile);
+
+ $user->query('COMMIT');
$this->show_form(_t('Settings saved.'), TRUE);
}