X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;ds=sidebyside;f=plugins%2FQnA%2Factions%2Fqnashowquestion.php;h=ca2cb74ba1d751c2279b4c5db7007a39f154b02d;hb=0b53b6768e03932f4beec6b6655763e6ecedc36d;hp=c30464bbf61aed2efb03f27f17892512910ebf1c;hpb=19b965d99188fde59cdd39b668df8951bc0f180c;p=quix0rs-gnu-social.git diff --git a/plugins/QnA/actions/qnashowquestion.php b/plugins/QnA/actions/qnashowquestion.php index c30464bbf6..ca2cb74ba1 100644 --- a/plugins/QnA/actions/qnashowquestion.php +++ b/plugins/QnA/actions/qnashowquestion.php @@ -57,7 +57,7 @@ class QnashowquestionAction extends ShownoticeAction */ function prepare($argarray) { - OwnerDesignAction::prepare($argarray); + Action::prepare($argarray); $this->id = $this->trimmed('id'); @@ -115,13 +115,7 @@ class QnashowquestionAction extends ShownoticeAction } if (count($answerIds) > 0) { - $notice = new Notice(); - $notice->query( - sprintf( - 'SELECT notice.* FROM notice WHERE notice.id IN (%s)', - implode(',', $answerIds) - ) - ); + $notice = Notice::multiGet('id', $answerIds); $nli = new NoticeList($notice, $this); $nli->show(); @@ -151,9 +145,9 @@ class QnashowquestionAction extends ShownoticeAction */ function title() { - // TRANS: Page title for a question. - // TRANS: %1$s is the nickname of the user who asked the question, %2$s is the question. return sprintf( + // TRANS: Page title for a question. + // TRANS: %1$s is the nickname of the user who asked the question, %2$s is the question. _m('%1$s\'s question: %2$s'), $this->user->nickname, $this->question->title @@ -168,7 +162,6 @@ class QnashowquestionAction extends ShownoticeAction return Action::lastModified(); } - /** * @fixme combine the notice time with question update time */