X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2Fspecials%2FSpecialDiff.php;h=8b5d31a8fb6a28760f924423bab7ec9ccd37479b;hb=440d21b0d9eed439507d1389a625a354d79cb17f;hp=77d23173ca8768be221c04ef240fe45de6ea264b;hpb=166191535f486569277e95b7e6a3850b5db6757d;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/specials/SpecialDiff.php b/includes/specials/SpecialDiff.php index 77d23173ca..8b5d31a8fb 100644 --- a/includes/specials/SpecialDiff.php +++ b/includes/specials/SpecialDiff.php @@ -37,12 +37,16 @@ * @since 1.23 */ class SpecialDiff extends RedirectSpecialPage { - function __construct() { + public function __construct() { parent::__construct( 'Diff' ); $this->mAllowedRedirectParams = array(); } - function getRedirect( $subpage ) { + /** + * @param string|null $subpage + * @return Title|bool + */ + public function getRedirect( $subpage ) { $parts = explode( '/', $subpage ); // Try to parse the values given, generating somewhat pretty URLs if possible @@ -53,6 +57,7 @@ class SpecialDiff extends RedirectSpecialPage { $this->mAddedRedirectParams['diff'] = $parts[1]; } else { // Wrong number of parameters, bail out + $this->addHelpLink( 'Help:Diff' ); throw new ErrorPageError( 'nopagetitle', 'nopagetext' ); }