summaryrefslogtreecommitdiff
path: root/actions/login.php
diff options
context:
space:
mode:
Diffstat (limited to 'actions/login.php')
-rw-r--r--actions/login.php7
1 files changed, 6 insertions, 1 deletions
diff --git a/actions/login.php b/actions/login.php
index 60c95343f..293d07fae 100644
--- a/actions/login.php
+++ b/actions/login.php
@@ -38,7 +38,12 @@ class LoginAction extends Action {
$nickname = $this->arg('nickname');
$password = $this->arg('password');
if (common_check_user($nickname, $password)) {
- common_set_user($nickname);
+ # success!
+ if (!common_set_user($nickname)) {
+ common_server_error(_t('Error setting user.'));
+ return;
+ }
+ # success!
common_redirect(common_local_url('all',
array('nickname' =>
$nickname)));