X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=actions%2Fattachment.php;h=b532b81d88438ddbf5a91b3a5e854129137531fb;hb=418b3c3c53194040022c4b56bd0c0b04fd6fd4d7;hp=45aa78728a2510d08182371950e2e0f66112cc9d;hpb=01f32e3998b8d031d2a39e2d0506253142b6632e;p=quix0rs-gnu-social.git diff --git a/actions/attachment.php b/actions/attachment.php index 45aa78728a..b532b81d88 100644 --- a/actions/attachment.php +++ b/actions/attachment.php @@ -60,18 +60,17 @@ class AttachmentAction extends Action * @return success flag */ - function prepare($args) + protected function prepare(array $args=array()) { parent::prepare($args); if ($id = $this->trimmed('attachment')) { - $this->attachment = File::staticGet($id); + $this->attachment = File::getKV($id); } if (empty($this->attachment)) { // TRANS: Client error displayed trying to get a non-existing attachment. $this->clientError(_('No such attachment.'), 404); - return false; } return true; } @@ -124,13 +123,11 @@ class AttachmentAction extends Action * * Only handles get, so just show the page. * - * @param array $args $_REQUEST data (unused) - * * @return void */ - function handle($args) + protected function handle() { - parent::handle($args); + parent::handle(); if (empty($this->attachment->filename)) { @@ -143,15 +140,6 @@ class AttachmentAction extends Action } } - /** - * Don't show local navigation - * - * @return void - */ - function showLocalNavBlock() - { - } - /** * Fill the content area of the page * @@ -182,7 +170,9 @@ class AttachmentAction extends Action function showSections() { $ns = new AttachmentNoticeSection($this); $ns->show(); - $atcs = new AttachmentTagCloudSection($this); - $atcs->show(); + if (!common_config('performance', 'high')) { + $atcs = new AttachmentTagCloudSection($this); + $atcs->show(); + } } }