Hide file links in action=info's 'Number of redirects to this page'
authorRicordisamoa <ricordisamoa@openmailbox.org>
Wed, 10 Dec 2014 01:29:14 +0000 (01:29 +0000)
committerBartosz Dziewoński <matma.rex@gmail.com>
Sat, 20 Dec 2014 01:18:18 +0000 (01:18 +0000)
Special:WhatLinksHere gets now passed hideimages=1
if the concerned page is in the File namespace.

A bit of history:
the 'hideimages' parameter has been added to Special:WhatLinksHere
with commit 06ad0d25 (r34267), then removed with commit cdc7e22d
(r34277), and finally added back with 725cb284 (r34320).

Change-Id: I0f358e52c38bb525cee8085ca206118ee276889d

RELEASE-NOTES-1.25
includes/actions/InfoAction.php

index 06d2d66..9e728ab 100644 (file)
@@ -109,6 +109,8 @@ production.
 ** Title::moveTo() was deprecated. Use the MovePage class instead.
 ** Title::isValidMoveOperation() broken down into MovePage::isValidMove()
    and MovePage::checkPermissions().
+* The Special:WhatLinksHere page linked from 'Number of redirects to this page'
+  on action=info about a file page does not list file links anymore.
 
 === Action API changes in 1.25 ===
 * (T67403) XML tag highlighting is now only performed for formats
index e7455f6..2d60044 100644 (file)
@@ -338,7 +338,11 @@ class InfoAction extends FormlessAction {
                                $whatLinksHere,
                                $this->msg( 'pageinfo-redirects-name' )->escaped(),
                                array(),
-                               array( 'hidelinks' => 1, 'hidetrans' => 1 )
+                               array(
+                                       'hidelinks' => 1,
+                                       'hidetrans' => 1,
+                                       'hideimages' => $title->getNamespace() == NS_FILE
+                               )
                        ),
                        $this->msg( 'pageinfo-redirects-value' )
                                ->numParams( count( $title->getRedirectsHere() ) )