summaryrefslogtreecommitdiff
path: root/actions
diff options
context:
space:
mode:
authorEvan Prodromou <evan@prodromou.name>2008-08-05 23:45:15 -0400
committerEvan Prodromou <evan@prodromou.name>2008-08-05 23:45:15 -0400
commit4c8dfadf2d11373d9518fea94a05d4a04f74589e (patch)
tree2628bf432ac23b20f322db40f038a02bbddbd368 /actions
parent120970434e01be250f643df79bda21169060fb6e (diff)
make init of lang environment happen earlier, or when user language may have changed
darcs-hash:20080806034515-84dde-e32cbfec2890f50b610d0441659180038b060473.gz
Diffstat (limited to 'actions')
-rw-r--r--actions/profilesettings.php3
-rw-r--r--actions/register.php2
2 files changed, 5 insertions, 0 deletions
diff --git a/actions/profilesettings.php b/actions/profilesettings.php
index f2fe89826..bc4fce50b 100644
--- a/actions/profilesettings.php
+++ b/actions/profilesettings.php
@@ -140,6 +140,9 @@ class ProfilesettingsAction extends SettingsAction {
common_log_db_error($user, 'UPDATE', __FILE__);
common_server_error(_('Couldn\'t update user.'));
return;
+ } else {
+ # Re-initialize language environment if it changed
+ common_init_language();
}
}
diff --git a/actions/register.php b/actions/register.php
index d97e3a18a..c53910842 100644
--- a/actions/register.php
+++ b/actions/register.php
@@ -98,6 +98,8 @@ class RegisterAction extends Action {
common_debug('Adding rememberme cookie for ' . $nickname);
common_rememberme($user);
}
+ # Re-init language env in case it changed (not yet, but soon)
+ common_init_language();
$this->show_success();
} else {
$this->show_form(_('Invalid username or password.'));