From 0718021090b3daa5fec3908a2428a26aeb878924 Mon Sep 17 00:00:00 2001 From: Isarra Date: Fri, 16 Aug 2019 16:46:32 +0000 Subject: [PATCH] Remove 'redundant' attribute from BaseTemplate::makeListItem() links in case this is not done in SkinTemplate::buildContentActionUrls() Not all skins are going to use buildContentActionUrls() in the first place, as they may not be laying out the usual action tabs as, well, the usual action tabs. Given that this is being added in core, it should likewise be cleaned up in core. Bug: T214202 Change-Id: I630410aea2852f7a72fea67bbf256b3561ea0f3f --- includes/skins/BaseTemplate.php | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/includes/skins/BaseTemplate.php b/includes/skins/BaseTemplate.php index cd79259e5e..cad69a594e 100644 --- a/includes/skins/BaseTemplate.php +++ b/includes/skins/BaseTemplate.php @@ -466,6 +466,10 @@ abstract class BaseTemplate extends QuickTemplate { * @return string */ function makeListItem( $key, $item, $options = [] ) { + // In case this is still set from SkinTemplate, we don't want it to appear in + // the HTML output (normally removed in SkinTemplate::buildContentActionUrls()) + unset( $item['redundant'] ); + if ( isset( $item['links'] ) ) { $links = []; foreach ( $item['links'] as $linkKey => $link ) { -- 2.20.1