return new $conf['class'](
new ServiceOptions(
- LocalisationCache::$constructorOptions,
+ LocalisationCache::CONSTRUCTOR_OPTIONS,
// Two of the options are stored in $wgLocalisationCacheConf
$conf,
// In case someone set that config variable and didn't reset all keys, set defaults.
}
/**
- * @todo Make this a const when HHVM support is dropped (T192166)
- *
* @var array
* @since 1.34
*/
- public static $constructorOptions = [
+ public const CONSTRUCTOR_OPTIONS = [
// True to treat all files as expired until they are regenerated by this object.
'forceRecache',
'manualRecache',
LoggerInterface $logger,
array $clearStoreCallbacks = []
) {
- $options->assertRequiredOptions( self::$constructorOptions );
+ $options->assertRequiredOptions( self::CONSTRUCTOR_OPTIONS );
$this->options = $options;
$this->store = $store;
// XXX Copy-pasted from ServiceWiring.php. Do we need a factory for this one caller?
$lc = new LocalisationCacheBulkLoad(
new ServiceOptions(
- LocalisationCache::$constructorOptions,
+ LocalisationCache::CONSTRUCTOR_OPTIONS,
$conf,
MediaWikiServices::getInstance()->getMainConfig()
),
$lc = $this->getMockBuilder( LocalisationCache::class )
->setConstructorArgs( [
- new ServiceOptions( LocalisationCache::$constructorOptions, [
+ new ServiceOptions( LocalisationCache::CONSTRUCTOR_OPTIONS, [
'forceRecache' => false,
'manualRecache' => false,
'ExtensionMessagesFiles' => [],