mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Popups
synced 2024-11-23 23:24:39 +00:00
0f087ce5e9
* php-parallel-lint/php-parallel-lint: 1.0.0 → 1.3.0 * mediawiki/mediawiki-codesniffer: 35.0.0 → 36.0.0 * mediawiki/minus-x: 1.1.0 → 1.1.1 Libup is broken on the build steps due to different node versions Change-Id: I28aefe77365b9812f9cc0f9e5177f45e9f5c2cc2
47 lines
1.4 KiB
PHP
47 lines
1.4 KiB
PHP
<?php
|
|
|
|
use MediaWiki\Logger\LoggerFactory;
|
|
use MediaWiki\MediaWikiServices;
|
|
use Popups\EventLogging\EventLoggerFactory;
|
|
use Popups\PopupsContext;
|
|
use Popups\PopupsGadgetsIntegration;
|
|
use Popups\UserPreferencesChangeHandler;
|
|
|
|
/**
|
|
* @codeCoverageIgnore
|
|
*/
|
|
return [
|
|
'Popups.Config' => static function ( MediaWikiServices $services ) {
|
|
return $services->getService( 'ConfigFactory' )
|
|
->makeConfig( PopupsContext::EXTENSION_NAME );
|
|
},
|
|
'Popups.GadgetsIntegration' => static function ( MediaWikiServices $services ) {
|
|
return new PopupsGadgetsIntegration(
|
|
$services->getService( 'Popups.Config' ),
|
|
ExtensionRegistry::getInstance()
|
|
);
|
|
},
|
|
'Popups.EventLogger' => static function ( MediaWikiServices $services ) {
|
|
$factory = new EventLoggerFactory(
|
|
ExtensionRegistry::getInstance()
|
|
);
|
|
return $factory->get();
|
|
},
|
|
'Popups.UserPreferencesChangeHandler' => static function ( MediaWikiServices $services ) {
|
|
return new UserPreferencesChangeHandler(
|
|
$services->getService( 'Popups.Context' )
|
|
);
|
|
},
|
|
'Popups.Logger' => static function ( MediaWikiServices $services ) {
|
|
return LoggerFactory::getInstance( PopupsContext::LOGGER_CHANNEL );
|
|
},
|
|
'Popups.Context' => static function ( MediaWikiServices $services ) {
|
|
return new PopupsContext(
|
|
$services->getService( 'Popups.Config' ),
|
|
ExtensionRegistry::getInstance(),
|
|
$services->getService( 'Popups.GadgetsIntegration' ),
|
|
$services->getService( 'Popups.EventLogger' )
|
|
);
|
|
}
|
|
];
|