Stop always loading MonoBook and Vector
authorBartosz Dziewoński <matma.rex@gmail.com>
Tue, 22 Jul 2014 21:32:53 +0000 (23:32 +0200)
committerLegoktm <legoktm.wikipedia@gmail.com>
Thu, 7 Aug 2014 14:06:34 +0000 (14:06 +0000)
Removing the hack added in Ib4bdda5e.

This will cause an error message to be shown to almost every MediaWiki
user who upgrades their installation (including us developers) until
they add entries for their skins to LocalSettings. This is deemed an
acceptable trade-off, and the message makes it easy to resolve the
issue.

Bug: 68402
Change-Id: I2596ef73088ce94d78ce3dc3ae4da9d81023a2cb

includes/Setup.php
tests/phpunit/includes/OutputPageTest.php

index 1eb04c3..935fa15 100644 (file)
@@ -78,14 +78,6 @@ if ( $wgExtensionAssetsPath === false ) {
        $wgExtensionAssetsPath = "$wgScriptPath/extensions";
 }
 
-// Enable default skins. Temporary, to be removed before 1.24 release.
-// This is hacky and bad, the require_once calls should eventually be generated by the installer
-// and placed in LocalSettings.php.
-// While this is in Setup.php, it needs to be done as soon as possible, as some of the setup code
-// depends on all extensions and skins being already required (bug 67318).
-require_once "$wgStyleDirectory/MonoBook/MonoBook.php";
-require_once "$wgStyleDirectory/Vector/Vector.php";
-
 if ( $wgLogo === false ) {
        $wgLogo = "$wgStylePath/common/images/wiki.png";
 }
index 2cfdfcd..e866386 100644 (file)
@@ -141,14 +141,14 @@ class OutputPageTest extends MediaWikiTestCase {
                        // Load module script only
                        array(
                                array( 'test.foo', ResourceLoaderModule::TYPE_SCRIPTS ),
-                               '<script src="http://127.0.0.1:8080/w/load.php?debug=false&amp;lang=en&amp;modules=test.foo&amp;only=scripts&amp;skin=vector&amp;*"></script>
+                               '<script src="http://127.0.0.1:8080/w/load.php?debug=false&amp;lang=en&amp;modules=test.foo&amp;only=scripts&amp;skin=fallback&amp;*"></script>
 '
                        ),
                        // Load module styles only
                        // This also tests the order the modules are put into the url
                        array(
                                array( array( 'test.baz', 'test.foo', 'test.bar' ), ResourceLoaderModule::TYPE_STYLES ),
-                               '<link rel=stylesheet href="http://127.0.0.1:8080/w/load.php?debug=false&amp;lang=en&amp;modules=test.bar%2Cbaz%2Cfoo&amp;only=styles&amp;skin=vector&amp;*">
+                               '<link rel=stylesheet href="http://127.0.0.1:8080/w/load.php?debug=false&amp;lang=en&amp;modules=test.bar%2Cbaz%2Cfoo&amp;only=styles&amp;skin=fallback&amp;*">
 '
                        ),
                        // Load private module (combined)
@@ -163,13 +163,13 @@ mw.loader.implement("test.quux",function($,jQuery){mw.test.baz({token:123});},{"
                        // Load module script with with ESI
                        array(
                                array( 'test.foo', ResourceLoaderModule::TYPE_SCRIPTS, true ),
-                               '<script><esi:include src="http://127.0.0.1:8080/w/load.php?debug=false&amp;lang=en&amp;modules=test.foo&amp;only=scripts&amp;skin=vector&amp;*" /></script>
+                               '<script><esi:include src="http://127.0.0.1:8080/w/load.php?debug=false&amp;lang=en&amp;modules=test.foo&amp;only=scripts&amp;skin=fallback&amp;*" /></script>
 '
                        ),
                        // Load module styles with with ESI
                        array(
                                array( 'test.foo', ResourceLoaderModule::TYPE_STYLES, true ),
-                               '<style><esi:include src="http://127.0.0.1:8080/w/load.php?debug=false&amp;lang=en&amp;modules=test.foo&amp;only=styles&amp;skin=vector&amp;*" /></style>
+                               '<style><esi:include src="http://127.0.0.1:8080/w/load.php?debug=false&amp;lang=en&amp;modules=test.foo&amp;only=styles&amp;skin=fallback&amp;*" /></style>
 ',
                        ),
                );