X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=actions%2Freplies.php;h=11d9c7c706cc29a777a326fa5b3e96ece2799e56;hb=0e52570bdce5f504c3e0ca6ed8a6cd381a0cd39f;hp=4c6fba9ece7206d0cc16c805e41b740a5481baef;hpb=2a4dc77a633cc78907934fd93200ac16d55be78e;p=quix0rs-gnu-social.git diff --git a/actions/replies.php b/actions/replies.php index 4c6fba9ece..11d9c7c706 100644 --- a/actions/replies.php +++ b/actions/replies.php @@ -59,7 +59,7 @@ class RepliesAction extends Action * * @return boolean success flag */ - function prepare($args) + function prepare(array $args=array()) { parent::prepare($args); @@ -70,7 +70,6 @@ class RepliesAction extends Action if (!$this->user) { // TRANS: Client error displayed when trying to reply to a non-exsting user. $this->clientError(_('No such user.')); - return false; } $profile = $this->user->getProfile(); @@ -78,7 +77,6 @@ class RepliesAction extends Action if (!$profile) { // TRANS: Error message displayed when referring to a user without a profile. $this->serverError(_('User has no profile.')); - return false; } $this->page = ($this->arg('page')) ? ($this->arg('page')+0) : 1; @@ -92,8 +90,8 @@ class RepliesAction extends Action NOTICES_PER_PAGE + 1); if($this->page > 1 && $this->notice->N == 0){ - // TRANS: Server error when page not found (404) - $this->serverError(_('No such page.'),$code=404); + // TRANS: Client error when page not found (404) + $this->clientError(_('No such page.'), 404); } return true; @@ -108,7 +106,7 @@ class RepliesAction extends Action * * @return void */ - function handle($args) + function handle(array $args=array()) { parent::handle($args); $this->showPage(); @@ -188,7 +186,7 @@ class RepliesAction extends Action */ function showContent() { - $nl = new NoticeList($this->notice, $this); + $nl = new PrimaryNoticeList($this->notice, $this, array('show_n'=>NOTICES_PER_PAGE)); $cnt = $nl->show(); if (0 === $cnt) { @@ -231,7 +229,7 @@ class RepliesAction extends Action $this->elementEnd('div'); } - function isReadOnly($args) + function isReadOnly(array $args=array()) { return true; }