mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Echo
synced 2024-11-15 03:35:01 +00:00
Use type-declaration on api module constructor
Parent class constructor gets type-declaration in 1145328459 Remove simple doc-blocks without further information Change-Id: I0ab283cd0510d8e85e93752a5ee7d65320a4ec2b
This commit is contained in:
parent
f5173fbd78
commit
2edd88a166
|
@ -19,7 +19,7 @@ class ApiEchoCreateEvent extends ApiBase {
|
||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
ApiMain $mainModule,
|
ApiMain $mainModule,
|
||||||
$moduleName,
|
string $moduleName,
|
||||||
UserNameUtils $userNameUtils
|
UserNameUtils $userNameUtils
|
||||||
) {
|
) {
|
||||||
parent::__construct( $mainModule, $moduleName );
|
parent::__construct( $mainModule, $moduleName );
|
||||||
|
|
|
@ -12,16 +12,10 @@ use Wikimedia\ParamValidator\ParamValidator;
|
||||||
|
|
||||||
class ApiEchoMute extends ApiBase {
|
class ApiEchoMute extends ApiBase {
|
||||||
|
|
||||||
/** @var CentralIdLookup */
|
private CentralIdLookup $centralIdLookup;
|
||||||
private $centralIdLookup;
|
private LinkBatchFactory $linkBatchFactory;
|
||||||
|
private UserOptionsManager $userOptionsManager;
|
||||||
|
|
||||||
/** @var LinkBatchFactory */
|
|
||||||
private $linkBatchFactory;
|
|
||||||
|
|
||||||
/** @var UserOptionsManager */
|
|
||||||
private $userOptionsManager;
|
|
||||||
|
|
||||||
/** @var string[][] */
|
|
||||||
private const MUTE_LISTS = [
|
private const MUTE_LISTS = [
|
||||||
'user' => [
|
'user' => [
|
||||||
'pref' => 'echo-notifications-blacklist',
|
'pref' => 'echo-notifications-blacklist',
|
||||||
|
@ -33,16 +27,9 @@ class ApiEchoMute extends ApiBase {
|
||||||
],
|
],
|
||||||
];
|
];
|
||||||
|
|
||||||
/**
|
|
||||||
* @param ApiMain $main
|
|
||||||
* @param string $action
|
|
||||||
* @param CentralIdLookup $centralIdLookup
|
|
||||||
* @param LinkBatchFactory $linkBatchFactory
|
|
||||||
* @param UserOptionsManager $userOptionsManager
|
|
||||||
*/
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
ApiMain $main,
|
ApiMain $main,
|
||||||
$action,
|
string $action,
|
||||||
CentralIdLookup $centralIdLookup,
|
CentralIdLookup $centralIdLookup,
|
||||||
LinkBatchFactory $linkBatchFactory,
|
LinkBatchFactory $linkBatchFactory,
|
||||||
UserOptionsManager $userOptionsManager
|
UserOptionsManager $userOptionsManager
|
||||||
|
|
|
@ -26,23 +26,15 @@ class ApiEchoUnreadNotificationPages extends ApiQueryBase {
|
||||||
*/
|
*/
|
||||||
protected $crossWikiSummary = false;
|
protected $crossWikiSummary = false;
|
||||||
|
|
||||||
/**
|
private PageStore $pageStore;
|
||||||
* @var PageStore
|
private TitleFactory $titleFactory;
|
||||||
*/
|
|
||||||
private $pageStore;
|
|
||||||
|
|
||||||
/**
|
public function __construct(
|
||||||
* @var TitleFactory
|
ApiQuery $query,
|
||||||
*/
|
string $moduleName,
|
||||||
private $titleFactory;
|
PageStore $pageStore,
|
||||||
|
TitleFactory $titleFactory
|
||||||
/**
|
) {
|
||||||
* @param ApiQuery $query
|
|
||||||
* @param string $moduleName
|
|
||||||
* @param PageStore $pageStore
|
|
||||||
* @param TitleFactory $titleFactory
|
|
||||||
*/
|
|
||||||
public function __construct( $query, $moduleName, PageStore $pageStore, TitleFactory $titleFactory ) {
|
|
||||||
parent::__construct( $query, $moduleName, 'unp' );
|
parent::__construct( $query, $moduleName, 'unp' );
|
||||||
$this->pageStore = $pageStore;
|
$this->pageStore = $pageStore;
|
||||||
$this->titleFactory = $titleFactory;
|
$this->titleFactory = $titleFactory;
|
||||||
|
|
Loading…
Reference in a new issue