Umherirrender has uploaded a new change for review. https://gerrit.wikimedia.org/r/80726
Change subject: Use redirect=no for links to file redirects in "file usages" section ...................................................................... Use redirect=no for links to file redirects in "file usages" section Bug: 50051 Change-Id: Ie77af42b2d9183ba2f56a300a6604c3f71ee89b8 --- M includes/ImagePage.php 1 file changed, 9 insertions(+), 1 deletion(-) git pull ssh://gerrit.wikimedia.org:29418/mediawiki/core refs/changes/26/80726/1 diff --git a/includes/ImagePage.php b/includes/ImagePage.php index 5fa44d5..7ea06b0 100644 --- a/includes/ImagePage.php +++ b/includes/ImagePage.php @@ -765,7 +765,15 @@ break; } - $link = Linker::linkKnown( Title::makeTitle( $element->page_namespace, $element->page_title ) ); + $query = array(); + # Add a redirect=no to make redirect pages reachable + if ( isset( $redirects[$element->page_title] ) ) { + $query['redirect'] = 'no'; + } + $link = Linker::linkKnown( + Title::makeTitle( $element->page_namespace, $element->page_title ), + null, array(), $query + ); if ( !isset( $redirects[$element->page_title] ) ) { # No redirects $liContents = $link; -- To view, visit https://gerrit.wikimedia.org/r/80726 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: newchange Gerrit-Change-Id: Ie77af42b2d9183ba2f56a300a6604c3f71ee89b8 Gerrit-PatchSet: 1 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Umherirrender <umherirrender_de...@web.de> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits