From bde1da2c588ec1289cec9752fd3c64871c479f8b Mon Sep 17 00:00:00 2001 From: =?utf8?q?Bartosz=20Dziewo=C5=84ski?= Date: Thu, 30 Jan 2014 01:25:30 +0100 Subject: [PATCH] ErrorPageError and subclasses use array() instead of null per their docs Follow-up to I227a416f. I think I've gotten them all. Change-Id: I521ad886a804718f8a3871491a1ca910e532bfb0 --- includes/Exception.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/includes/Exception.php b/includes/Exception.php index 5377add7ec..d8c7b6aa87 100644 --- a/includes/Exception.php +++ b/includes/Exception.php @@ -317,7 +317,7 @@ class ErrorPageError extends MWException { * @param string|Message $msg Message key (string) for error text, or a Message object * @param array $params with parameters to wfMessage() */ - function __construct( $title, $msg, $params = null ) { + function __construct( $title, $msg, $params = array() ) { $this->title = $title; $this->msg = $msg; $this->params = $params; @@ -356,7 +356,7 @@ class BadTitleError extends ErrorPageError { * @param string|Message $msg A message key (default: 'badtitletext') * @param array $params parameter to wfMessage() */ - function __construct( $msg = 'badtitletext', $params = null ) { + function __construct( $msg = 'badtitletext', $params = array() ) { parent::__construct( 'badtitle', $msg, $params ); } @@ -426,7 +426,7 @@ class ReadOnlyError extends ErrorPageError { parent::__construct( 'readonly', 'readonlytext', - wfReadOnlyReason() + wfReadOnlyReason() ?: array() ); } } @@ -501,12 +501,12 @@ class UserNotLoggedIn extends ErrorPageError { * @param string $titleMsg A message key to set the page title. * Optional, default: 'exception-nologin' * @param array $params Parameters to wfMessage(). - * Optional, default: null + * Optional, default: array() */ public function __construct( $reasonMsg = 'exception-nologin-text', $titleMsg = 'exception-nologin', - $params = null + $params = array() ) { parent::__construct( $titleMsg, $reasonMsg, $params ); } -- 2.20.1