From d76d37340a64d370bfdfd439b4dc9f700e680bf0 Mon Sep 17 00:00:00 2001 From: Mikael Nordfeldth Date: Sat, 6 Jun 2015 22:14:56 +0200 Subject: [PATCH] Function declarations not matching their parents --- actions/apiconversation.php | 11 ++--------- actions/conversation.php | 2 +- lib/clienterroraction.php | 4 ++-- lib/fullthreadednoticelist.php | 2 +- lib/servererroraction.php | 4 ++-- plugins/Mobile/WAP20Plugin.php | 2 +- plugins/QnA/QnAPlugin.php | 4 ++-- 7 files changed, 11 insertions(+), 18 deletions(-) diff --git a/actions/apiconversation.php b/actions/apiconversation.php index 0e292303d5..5e1102b2f6 100644 --- a/actions/apiconversation.php +++ b/actions/apiconversation.php @@ -49,16 +49,9 @@ class ApiconversationAction extends ApiAuthAction protected $conversation = null; protected $notices = null; - /** - * For initializing members of the class. - * - * @param array $argarray misc. arguments - * - * @return boolean true - */ - function prepare($argarray) + protected function prepare(array $args=array()) { - parent::prepare($argarray); + parent::prepare($args); $convId = $this->trimmed('id'); diff --git a/actions/conversation.php b/actions/conversation.php index 5a6e4b5c7a..b1cb50abac 100644 --- a/actions/conversation.php +++ b/actions/conversation.php @@ -97,7 +97,7 @@ class ConversationAction extends ManagedAction Event::handle('EndShowConversation', array($this, $this->conv, $this->scoped)); } - function isReadOnly() + function isReadOnly($args) { return true; } diff --git a/lib/clienterroraction.php b/lib/clienterroraction.php index 9233c9bde6..37f722291e 100644 --- a/lib/clienterroraction.php +++ b/lib/clienterroraction.php @@ -72,9 +72,9 @@ class ClientErrorAction extends ErrorAction // XXX: Should these error actions even be invokable via URI? - function handle($args) + protected function handle() { - parent::handle($args); + parent::handle(); $this->code = $this->trimmed('code'); diff --git a/lib/fullthreadednoticelist.php b/lib/fullthreadednoticelist.php index 52b5f279c9..0cc023ca5d 100644 --- a/lib/fullthreadednoticelist.php +++ b/lib/fullthreadednoticelist.php @@ -48,7 +48,7 @@ if (!defined('STATUSNET')) { class FullThreadedNoticeList extends ThreadedNoticeList { - function newListItem($notice) + function newListItem(Notice $notice) { return new FullThreadedNoticeListItem($notice, $this->out, $this->userProfile); } diff --git a/lib/servererroraction.php b/lib/servererroraction.php index 54cc99099a..c8e3067b82 100644 --- a/lib/servererroraction.php +++ b/lib/servererroraction.php @@ -78,9 +78,9 @@ class ServerErrorAction extends ErrorAction // XXX: Should these error actions even be invokable via URI? - function handle($args) + protected function handle() { - parent::handle($args); + parent::handle(); $this->code = $this->trimmed('code'); diff --git a/plugins/Mobile/WAP20Plugin.php b/plugins/Mobile/WAP20Plugin.php index fc5008cda6..a48a32e9f1 100644 --- a/plugins/Mobile/WAP20Plugin.php +++ b/plugins/Mobile/WAP20Plugin.php @@ -43,7 +43,7 @@ if (!defined('STATUSNET') && !defined('LACONICA')) { class WAP20Plugin extends Plugin { - function onStartShowHTML($action) + function onStartShowHTML(Action $action) { } diff --git a/plugins/QnA/QnAPlugin.php b/plugins/QnA/QnAPlugin.php index f64cd905cf..e8c983eb9a 100644 --- a/plugins/QnA/QnAPlugin.php +++ b/plugins/QnA/QnAPlugin.php @@ -260,7 +260,7 @@ class QnAPlugin extends MicroAppPlugin * @return boolean hook value */ - function onStartOpenNoticeListItemElement($nli) + function onStartOpenNoticeListItemElement(NoticeListItem $nli) { $type = $nli->notice->object_type; @@ -325,7 +325,7 @@ class QnAPlugin extends MicroAppPlugin * * @todo FIXME: WARNING WARNING WARNING this closes a 'div' that is implicitly opened in BookmarkPlugin's showNotice implementation */ - function onStartShowNoticeItem($nli) + function onStartShowNoticeItem(NoticeListItem $nli) { if (!$this->isMyNotice($nli->notice)) { return true; -- 2.39.5