dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "Add a test for ApiFormatNone"
[lhc/web/wiklou.git]
/
includes
/
resourceloader
/
ResourceLoaderStartUpModule.php
diff --git
a/includes/resourceloader/ResourceLoaderStartUpModule.php
b/includes/resourceloader/ResourceLoaderStartUpModule.php
index
7cfc81d
..
78fe45c
100644
(file)
--- a/
includes/resourceloader/ResourceLoaderStartUpModule.php
+++ b/
includes/resourceloader/ResourceLoaderStartUpModule.php
@@
-122,7
+122,7
@@
class ResourceLoaderStartUpModule extends ResourceLoaderModule {
* @param string $moduleName
* @return array
*/
* @param string $moduleName
* @return array
*/
- protected static function getImplicitDependencies(
A
rray $registryData, $moduleName ) {
+ protected static function getImplicitDependencies(
a
rray $registryData, $moduleName ) {
static $dependencyCache = array();
// The list of implicit dependencies won't be altered, so we can
static $dependencyCache = array();
// The list of implicit dependencies won't be altered, so we can
@@
-168,7
+168,7
@@
class ResourceLoaderStartUpModule extends ResourceLoaderModule {
* - string 'source'
* - string|false 'loader'
*/
* - string 'source'
* - string|false 'loader'
*/
- public static function compileUnresolvedDependencies(
A
rray &$registryData ) {
+ public static function compileUnresolvedDependencies(
a
rray &$registryData ) {
foreach ( $registryData as $name => &$data ) {
if ( $data['loader'] !== false ) {
continue;
foreach ( $registryData as $name => &$data ) {
if ( $data['loader'] !== false ) {
continue;
@@
-325,6
+325,15
@@
class ResourceLoaderStartUpModule extends ResourceLoaderModule {
return true;
}
return true;
}
+ /**
+ * Base modules required for the the base environment of ResourceLoader
+ *
+ * @return array
+ */
+ public static function getStartupModules() {
+ return array( 'jquery', 'mediawiki' );
+ }
+
/**
* Get the load URL of the startup modules.
*
/**
* Get the load URL of the startup modules.
*
@@
-335,8
+344,7
@@
class ResourceLoaderStartUpModule extends ResourceLoaderModule {
* @return string
*/
public static function getStartupModulesUrl( ResourceLoaderContext $context ) {
* @return string
*/
public static function getStartupModulesUrl( ResourceLoaderContext $context ) {
- // The core modules:
- $moduleNames = array( 'jquery', 'mediawiki' );
+ $moduleNames = self::getStartupModules();
// Get the latest version
$loader = $context->getResourceLoader();
// Get the latest version
$loader = $context->getResourceLoader();