From f831b28d16db505926cda79d538e884122dfe566 Mon Sep 17 00:00:00 2001 From: Timo Tijhof Date: Mon, 15 Apr 2019 19:02:55 +0100 Subject: [PATCH] resourceloader: Remove 'wgMainPageTitle' mw.config key This was added in 2009 with cf75bdf4ba (r54384) and moved to the startup module in 2010 with a99f9ec28b9 (r72772). It is no longer used by any extension in Wikimedia Git, nor elsewhere indexed by MediaWiki Codesearch. It also no longer has any uses in mwgrep from public WMF wikis. Bug: T220926 Depends-On: Ifdedccb513f5dd4636a37badc329ac5f1c4dd943 Change-Id: Id2729653cd450d31c1d903358ccf5e4fac564228 --- includes/resourceloader/ResourceLoaderStartUpModule.php | 5 ----- 1 file changed, 5 deletions(-) diff --git a/includes/resourceloader/ResourceLoaderStartUpModule.php b/includes/resourceloader/ResourceLoaderStartUpModule.php index da6063ea89..69a6f5ff1a 100644 --- a/includes/resourceloader/ResourceLoaderStartUpModule.php +++ b/includes/resourceloader/ResourceLoaderStartUpModule.php @@ -49,10 +49,6 @@ class ResourceLoaderStartUpModule extends ResourceLoaderModule { private function getConfigSettings( $context ) { $conf = $this->getConfig(); - // Passing a context is important as Title::newMainPage() may otherwise - // try to intialise a session, which is not allowed on load.php requests. - $mainPage = Title::newMainPage( $context ); - /** * Namespace related preparation * - wgNamespaceIds: Key-value pairs of all localized, canonical and aliases for namespaces. @@ -94,7 +90,6 @@ class ResourceLoaderStartUpModule extends ResourceLoaderModule { 'wgVersion' => $conf->get( 'Version' ), 'wgEnableAPI' => true, // Deprecated since MW 1.32 'wgEnableWriteAPI' => true, // Deprecated since MW 1.32 - 'wgMainPageTitle' => $mainPage->getPrefixedText(), 'wgFormattedNamespaces' => $contLang->getFormattedNamespaces(), 'wgNamespaceIds' => $namespaceIds, 'wgContentNamespaces' => MWNamespace::getContentNamespaces(), -- 2.20.1