From 4b0cf99e56f965e10eeb8b8b19e7b405bda49eaf Mon Sep 17 00:00:00 2001 From: Evan Prodromou Date: Thu, 15 Jan 2009 23:03:38 +0000 Subject: Convert use of common_server_error and common_user_error to methods on Action --- actions/newmessage.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'actions/newmessage.php') diff --git a/actions/newmessage.php b/actions/newmessage.php index 6221b67e9..510a5f8f3 100644 --- a/actions/newmessage.php +++ b/actions/newmessage.php @@ -27,7 +27,7 @@ class NewmessageAction extends Action parent::handle($args); if (!common_logged_in()) { - $this->client_error(_('Not logged in.'), 403); + $this->clientError(_('Not logged in.'), 403); } else if ($_SERVER['REQUEST_METHOD'] == 'POST') { $this->save_new_message(); } else { @@ -71,10 +71,10 @@ class NewmessageAction extends Action $this->show_form(_('No recipient specified.')); return; } else if (!$user->mutuallySubscribed($other)) { - $this->client_error(_('You can\'t send a message to this user.'), 404); + $this->clientError(_('You can\'t send a message to this user.'), 404); return; } else if ($user->id == $other->id) { - $this->client_error(_('Don\'t send a message to yourself; just say it to yourself quietly instead.'), 403); + $this->clientError(_('Don\'t send a message to yourself; just say it to yourself quietly instead.'), 403); return; } @@ -113,12 +113,12 @@ class NewmessageAction extends Action $other = User::staticGet('id', $to); if (!$other) { - $this->client_error(_('No such user'), 404); + $this->clientError(_('No such user'), 404); return; } if (!$user->mutuallySubscribed($other)) { - $this->client_error(_('You can\'t send a message to this user.'), 404); + $this->clientError(_('You can\'t send a message to this user.'), 404); return; } -- cgit v1.2.3-54-g00ecf