mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Gadgets
synced 2024-09-23 10:22:21 +00:00
Merge "Hard deprecate GadgetRepo::singleton and GadgetRepo::setSingleton"
This commit is contained in:
commit
d455cbd512
|
@ -240,6 +240,7 @@ abstract class GadgetRepo {
|
|||
* @return GadgetRepo
|
||||
*/
|
||||
public static function singleton() {
|
||||
wfDeprecated( __METHOD__, '1.42' );
|
||||
if ( self::$instance === null ) {
|
||||
return MediaWikiServices::getInstance()->getService( 'GadgetsRepo' );
|
||||
}
|
||||
|
@ -253,6 +254,7 @@ abstract class GadgetRepo {
|
|||
* @param GadgetRepo|null $repo
|
||||
*/
|
||||
public static function setSingleton( $repo = null ) {
|
||||
wfDeprecated( __METHOD__, '1.42' );
|
||||
self::$instance = $repo;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue