X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=includes%2FServiceWiring.php;h=7d2b3cb14f2845bfdadae2d4379ef4dc974c7b8d;hb=8963110d01b0f376d900171fe7506fed5df80cf8;hp=c5764d22628c72d2e6fe6eb85c84bf63a3933b2a;hpb=af7ae6c804be8629fe2305e3a088f03e1af2fa9b;p=lhc%2Fweb%2Fwiklou.git diff --git a/includes/ServiceWiring.php b/includes/ServiceWiring.php index c5764d2262..7d2b3cb14f 100644 --- a/includes/ServiceWiring.php +++ b/includes/ServiceWiring.php @@ -82,6 +82,7 @@ return [ 'BlobStoreFactory' => function ( MediaWikiServices $services ) : BlobStoreFactory { return new BlobStoreFactory( $services->getDBLoadBalancerFactory(), + $services->getExternalStoreAccess(), $services->getMainWANObjectCache(), new ServiceOptions( BlobStoreFactory::$constructorOptions, $services->getMainConfig() ), @@ -93,16 +94,11 @@ return [ $config = $services->getMainConfig(); $context = RequestContext::getMain(); return new BlockManager( + new ServiceOptions( + BlockManager::$constructorOptions, $services->getMainConfig() + ), $context->getUser(), - $context->getRequest(), - $config->get( 'ApplyIpBlocksToXff' ), - $config->get( 'CookieSetOnAutoblock' ), - $config->get( 'CookieSetOnIpBlock' ), - $config->get( 'DnsBlacklistUrls' ), - $config->get( 'EnableDnsBlacklist' ), - $config->get( 'ProxyList' ), - $config->get( 'ProxyWhitelist' ), - $config->get( 'SoftBlockRanges' ) + $context->getRequest() ); }, @@ -200,11 +196,22 @@ return [ return new EventRelayerGroup( $services->getMainConfig()->get( 'EventRelayerConfig' ) ); }, + 'ExternalStoreAccess' => function ( MediaWikiServices $services ) : ExternalStoreAccess { + return new ExternalStoreAccess( + $services->getExternalStoreFactory(), + LoggerFactory::getInstance( 'ExternalStore' ) + ); + }, + 'ExternalStoreFactory' => function ( MediaWikiServices $services ) : ExternalStoreFactory { $config = $services->getMainConfig(); + $writeStores = $config->get( 'DefaultExternalStore' ); return new ExternalStoreFactory( - $config->get( 'ExternalStores' ) + $config->get( 'ExternalStores' ), + ( $writeStores !== false ) ? (array)$writeStores : [], + $services->getDBLoadBalancer()->getLocalDomainID(), + LoggerFactory::getInstance( 'ExternalStore' ) ); }, @@ -463,6 +470,9 @@ return [ $config->get( 'WhitelistReadRegexp' ), $config->get( 'EmailConfirmToEdit' ), $config->get( 'BlockDisablesLogin' ), + $config->get( 'GroupPermissions' ), + $config->get( 'RevokePermissions' ), + $config->get( 'AvailableRights' ), $services->getNamespaceInfo() ); },