summaryrefslogtreecommitdiff
path: root/actions/login.php
diff options
context:
space:
mode:
authorEvan Prodromou <evan@controlyourself.ca>2009-01-15 23:03:38 +0000
committerEvan Prodromou <evan@controlyourself.ca>2009-01-15 23:03:38 +0000
commit4b0cf99e56f965e10eeb8b8b19e7b405bda49eaf (patch)
tree094c2948648d79290326130f9cd75a95afc6035d /actions/login.php
parenteaa81d25fa7bd954132ce7f901fae69b0d46ec1a (diff)
Convert use of common_server_error and common_user_error to methods on Action
Diffstat (limited to 'actions/login.php')
-rw-r--r--actions/login.php8
1 files changed, 4 insertions, 4 deletions
diff --git a/actions/login.php b/actions/login.php
index fd98e656d..060d16ad6 100644
--- a/actions/login.php
+++ b/actions/login.php
@@ -31,7 +31,7 @@ class LoginAction extends Action
{
parent::handle($args);
if (common_is_real_login()) {
- common_user_error(_('Already logged in.'));
+ $this->clientError(_('Already logged in.'));
} else if ($_SERVER['REQUEST_METHOD'] == 'POST') {
$this->check_login();
} else {
@@ -46,7 +46,7 @@ class LoginAction extends Action
# CSRF protection - token set in common_notice_form()
$token = $this->trimmed('token');
if (!$token || $token != common_session_token()) {
- $this->client_error(_('There was a problem with your session token. Try again, please.'));
+ $this->clientError(_('There was a problem with your session token. Try again, please.'));
return;
}
@@ -55,7 +55,7 @@ class LoginAction extends Action
if (common_check_user($nickname, $password)) {
# success!
if (!common_set_user($nickname)) {
- common_server_error(_('Error setting user.'));
+ $this->serverError(_('Error setting user.'));
return;
}
common_real_login(true);
@@ -81,7 +81,7 @@ class LoginAction extends Action
# success!
if (!common_set_user($user)) {
- common_server_error(_('Error setting user.'));
+ $this->serverError(_('Error setting user.'));
return;
}