mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Gadgets
synced 2024-09-23 10:22:21 +00:00
Hard deprecate GadgetRepo::singleton and GadgetRepo::setSingleton
The two methodes are deprecated since I0ab14ca936eec1eead91d4eb0970f898628c8388 included in REL1_42. Depends-On: Ic3343446b1a41760eb1b8fd1e9ad557abac89639 Depends-On: Iae5cf4c0a0d8fdac7e291fdeb0e7f4e4a78a1d58 Depends-On: I226b259e361d3d27ec89975353fdf6396ba60ccb Depends-On: Ib405ad79b3c348bed51a8938a6a8f73bd35267d2 Depends-On: I41d1516e185ceb5c49b38361360a3adad1a333de Change-Id: I5452a46ee5fd85efb3835a108c947950945e91f3
This commit is contained in:
parent
6fed9643c8
commit
cfa04f8c1e
|
@ -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