DX: apply rector rules up to php8.0

This commit is contained in:
2023-04-15 01:05:37 +02:00
parent d8870e906f
commit dde3002100
714 changed files with 2348 additions and 9263 deletions

View File

@@ -22,21 +22,11 @@ class PasswordRecoverEvent extends Event
public const INVALID_TOKEN = 'chill_main.password_recover_invalid_token';
/**
* @var string
*/
protected $ip;
/**
* @var bool
*/
protected $safelyGenerated;
/**
* @var string
*/
protected $token;
/**
* @var User
*/
@@ -48,11 +38,9 @@ class PasswordRecoverEvent extends Event
* @param type $ip
* @param bool $safelyGenerated true if generated safely (from console command, etc.)
*/
public function __construct($token = null, ?User $user = null, $ip = null, bool $safelyGenerated = false)
public function __construct(protected $token = null, ?User $user = null, protected $ip = null, bool $safelyGenerated = false)
{
$this->user = $user;
$this->token = $token;
$this->ip = $ip;
$this->safelyGenerated = $safelyGenerated;
}
@@ -69,10 +57,7 @@ class PasswordRecoverEvent extends Event
return $this->token;
}
/**
* @return User|null
*/
public function getUser()
public function getUser(): ?\Chill\MainBundle\Entity\User
{
return $this->user;
}