mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/LoginNotify
synced 2024-09-23 10:20:21 +00:00
87dd7827ee
Provided services are already type-hinted on the construtor and it is safe to use the same type on the class property Change-Id: I15b5346353100e2e55d68b0a52fe3398778d60a5
21 lines
452 B
PHP
21 lines
452 B
PHP
<?php
|
|
|
|
namespace LoginNotify;
|
|
|
|
use MediaWiki\Title\Title;
|
|
|
|
class PurgeSeenJob extends \Job {
|
|
private LoginNotify $loginNotify;
|
|
|
|
public function __construct( Title $title, array $params, LoginNotify $loginNotify ) {
|
|
parent::__construct( 'LoginNotifyPurgeSeen', $title, $params );
|
|
$this->loginNotify = $loginNotify;
|
|
}
|
|
|
|
public function run() {
|
|
$minId = $this->getParams()['minId'];
|
|
$this->loginNotify->purgeSeen( $minId );
|
|
return true;
|
|
}
|
|
}
|