context: Replace deprecated use of SkinFactory::getDefaultInstance()
authorDerick Alangi <alangiderick@gmail.com>
Mon, 15 Apr 2019 19:21:21 +0000 (20:21 +0100)
committerDerick Alangi <alangiderick@gmail.com>
Mon, 15 Apr 2019 19:21:21 +0000 (20:21 +0100)
Replace with MediaWikiServices::getInstance()->getSkinFactory()

Change-Id: I2cf7afad249e52e13a56fbe92b1665dfebec793f

includes/context/RequestContext.php

index a4225a1..aada514 100644 (file)
@@ -368,7 +368,7 @@ class RequestContext implements IContextSource, MutableContext {
                if ( $this->skin === null ) {
                        $skin = null;
                        Hooks::run( 'RequestContextCreateSkin', [ $this, &$skin ] );
-                       $factory = SkinFactory::getDefaultInstance();
+                       $factory = MediaWikiServices::getInstance()->getSkinFactory();
 
                        // If the hook worked try to set a skin from it
                        if ( $skin instanceof Skin ) {