diff --git a/.phpcs.xml b/.phpcs.xml index 31ab3a1..eddb6dc 100644 --- a/.phpcs.xml +++ b/.phpcs.xml @@ -1,8 +1,6 @@ - - - + . diff --git a/includes/DeferredChecksJob.php b/includes/DeferredChecksJob.php index a178e37..ba2e88b 100644 --- a/includes/DeferredChecksJob.php +++ b/includes/DeferredChecksJob.php @@ -15,7 +15,7 @@ class DeferredChecksJob extends Job { public const TYPE_LOGIN_FAILED = 'failed'; public const TYPE_LOGIN_SUCCESS = 'success'; - private $userFactory; + private UserFactory $userFactory; /** * @param Title $title diff --git a/includes/Hooks.php b/includes/Hooks.php index 3b664ec..973b519 100644 --- a/includes/Hooks.php +++ b/includes/Hooks.php @@ -21,8 +21,7 @@ class Hooks implements LocalUserCreatedHook, RecentChange_saveHook { - /** @var UserFactory */ - private $userFactory; + private UserFactory $userFactory; public function __construct( UserFactory $userFactory ) { $this->userFactory = $userFactory; diff --git a/includes/LoginNotify.php b/includes/LoginNotify.php index 600d43e..8641368 100644 --- a/includes/LoginNotify.php +++ b/includes/LoginNotify.php @@ -74,26 +74,18 @@ class LoginNotify implements LoggerAwareInterface { /** We don't have data to confirm or deny this is a known system */ public const USER_NO_INFO = 'no info'; - /** @var BagOStuff */ - private $cache; - /** @var ServiceOptions */ - private $config; - /** @var LoggerInterface Usually instance of LoginNotify log */ - private $log; + private BagOStuff $cache; + private ServiceOptions $config; + private LoggerInterface $log; /** @var string Salt for cookie hash. DON'T USE DIRECTLY, use getSalt() */ private $salt; /** @var string */ private $secret; - /** @var IBufferingStatsdDataFactory */ - private $stats; - /** @var LBFactory */ - private $lbFactory; - /** @var JobQueueGroup */ - private $jobQueueGroup; - /** @var CentralIdLookup */ - private $centralIdLookup; - /** @var AuthManager */ - private $authManager; + private IBufferingStatsdDataFactory $stats; + private LBFactory $lbFactory; + private JobQueueGroup $jobQueueGroup; + private CentralIdLookup $centralIdLookup; + private AuthManager $authManager; /** @var int|null */ private $fakeTime; diff --git a/includes/PurgeSeenJob.php b/includes/PurgeSeenJob.php index 86c8085..21d1ed1 100644 --- a/includes/PurgeSeenJob.php +++ b/includes/PurgeSeenJob.php @@ -5,7 +5,7 @@ namespace LoginNotify; use MediaWiki\Title\Title; class PurgeSeenJob extends \Job { - private $loginNotify; + private LoginNotify $loginNotify; public function __construct( Title $title, array $params, LoginNotify $loginNotify ) { parent::__construct( 'LoginNotifyPurgeSeen', $title, $params );