From 674426de3c6d97706582b3f9915ac45dc791b173 Mon Sep 17 00:00:00 2001 From: Fomafix Date: Wed, 23 Sep 2015 16:34:46 +0000 Subject: [PATCH] SpecialNewpages: Add redirect=no only to links to redirects Since 2748c4091 all title links have redirect=no. This is requested in T16353. To satisfy T16353 it should be enough to add this only to links to redirects. Appending redirect=no to all links has the disadvantage of a duplicate link. This change adds redirect=no only to links to redirects. Change-Id: I33da0f1eadc5dfbc46820015622ee1a55acbfe21 --- includes/specials/SpecialNewpages.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/specials/SpecialNewpages.php b/includes/specials/SpecialNewpages.php index 251a8e0364..c8d4aa637c 100644 --- a/includes/specials/SpecialNewpages.php +++ b/includes/specials/SpecialNewpages.php @@ -315,7 +315,7 @@ class SpecialNewpages extends IncludableSpecialPage { array() ); - $query = array( 'redirect' => 'no' ); + $query = $title->isRedirect() ? array( 'redirect' => 'no' ) : array(); // Linker::linkKnown() uses 'known' and 'noclasses' options. // This breaks the colouration for stubs. -- 2.20.1