mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-08-27 18:13:48 +00:00
fix phpstan issues
This commit is contained in:
@@ -209,9 +209,9 @@ class AuthorizationHelper implements AuthorizationHelperInterface
|
||||
|
||||
throw new UnexpectedValueException(
|
||||
sprintf(
|
||||
'The entity given is not an instance of %s, %s given',
|
||||
'The entity given is not an instance of %s or an array of centers, %s given',
|
||||
Center::class,
|
||||
$center::class
|
||||
gettype($center)
|
||||
)
|
||||
);
|
||||
}
|
||||
|
@@ -23,25 +23,15 @@ class PasswordRecoverEvent extends Event
|
||||
public const INVALID_TOKEN = 'chill_main.password_recover_invalid_token';
|
||||
|
||||
/**
|
||||
* @var bool
|
||||
*/
|
||||
protected $safelyGenerated;
|
||||
|
||||
/**
|
||||
* @var User
|
||||
*/
|
||||
protected $user;
|
||||
|
||||
/**
|
||||
* @param type $token
|
||||
* @param User $user
|
||||
* @param type $ip
|
||||
* @param bool $safelyGenerated true if generated safely (from console command, etc.)
|
||||
*/
|
||||
public function __construct(protected $token = null, ?User $user = null, protected $ip = null, bool $safelyGenerated = false)
|
||||
public function __construct(
|
||||
private ?string $token = null,
|
||||
private ?User $user = null,
|
||||
private $ip = null,
|
||||
private bool $safelyGenerated = false,
|
||||
)
|
||||
{
|
||||
$this->user = $user;
|
||||
$this->safelyGenerated = $safelyGenerated;
|
||||
}
|
||||
|
||||
public function getIp()
|
||||
|
Reference in New Issue
Block a user