Hoo man has uploaded a new change for review.
https://gerrit.wikimedia.org/r/179008
Change subject: Compute $wgWBClientSettings['excludeNamespaces'] on demand
......................................................................
Compute $wgWBClientSettings['excludeNamespaces'] on demand
And not all the time
Change-Id: Iba616b200d16132782414fef8d2cda4ec9f9cd0b
---
M wmf-config/Wikibase.php
1 file changed, 2 insertions(+), 8 deletions(-)
git pull ssh://gerrit.wikimedia.org:29418/operations/mediawiki-config
refs/changes/08/179008/1
diff --git a/wmf-config/Wikibase.php b/wmf-config/Wikibase.php
index bdcf76b..b1c1910 100644
--- a/wmf-config/Wikibase.php
+++ b/wmf-config/Wikibase.php
@@ -166,18 +166,12 @@
'Q17580674' => 'badge-featuredportal', // bug 73193
);
- $wgHooks['SetupAfterCache'][] = 'wmfWBClientExcludeNS';
-
- function wmfWBClientExcludeNS() {
- global $wgWBClientSettings;
-
- $wgWBClientSettings['excludeNamespaces'] = array_merge(
+ $wgWBClientSettings['excludeNamespaces'] = function() {
+ return array_merge(
MWNamespace::getTalkNamespaces(),
// 1198 => NS_TRANSLATE
array( NS_USER, NS_FILE, NS_MEDIAWIKI, 1198 )
);
-
- return true;
};
$wgWBClientSettings['allowArbitraryDataAccess'] = false;
--
To view, visit https://gerrit.wikimedia.org/r/179008
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: newchange
Gerrit-Change-Id: Iba616b200d16132782414fef8d2cda4ec9f9cd0b
Gerrit-PatchSet: 1
Gerrit-Project: operations/mediawiki-config
Gerrit-Branch: master
Gerrit-Owner: Hoo man <[email protected]>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits