MalformedTitleException should call parent::__construct
authorBrad Jorsch <bjorsch@wikimedia.org>
Wed, 6 May 2015 18:42:38 +0000 (14:42 -0400)
committerBrad Jorsch <bjorsch@wikimedia.org>
Wed, 6 May 2015 20:11:51 +0000 (16:11 -0400)
commit132f1b1ea8ddf6662adf3d03c5bbc041fa409b9a
tree887a3d45ec500fcb5b1bedee4c6b87225f0220f6
parent3ae6b8ad5f57a7516ca7fe5a9bbe553dfc6c08bc
MalformedTitleException should call parent::__construct

There's no reason for $ex->getMessage() to return nothing. Do like
ErrorPageError does and get the default English message for the parent.

Also move the appending of $titleText to $errorMessageParameters into
MalformedTitleException itself and document it, so every catcher of the
exception doesn't need to know about this, and fix the check so it
doesn't screw up for title "0".

Change-Id: I43d988602b847b67a3cf0aa84e271a0b5bd9adae
includes/exception/BadTitleError.php
includes/title/MalformedTitleException.php