mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/WikiEditor
synced 2024-11-23 15:57:15 +00:00
Made ResourceLoader an instantiable object, rather than a static one, making it more modular and testable.
This commit is contained in:
parent
3bf3f43839
commit
00a8966b90
|
@ -687,9 +687,9 @@ class WikiEditorHooks {
|
|||
*
|
||||
* Adds modules to ResourceLoader
|
||||
*/
|
||||
public static function resourceLoaderRegisterModules() {
|
||||
public static function resourceLoaderRegisterModules( &$resourceLoader ) {
|
||||
foreach ( self::$modules as $name => $resources ) {
|
||||
ResourceLoader::register( $name, new ResourceLoaderFileModule( $resources ) );
|
||||
$resourceLoader->register( $name, new ResourceLoaderFileModule( $resources ) );
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue