diff --git a/Model/Client.php b/Model/Client.php index 356ac6d5..91f14bb1 100644 --- a/Model/Client.php +++ b/Model/Client.php @@ -24,14 +24,14 @@ class Client implements ClientInterface protected $id; /** - * @var string + * @var string|null */ - protected string $randomId; + protected ?string $randomId = null; /** - * @var string + * @var string|null */ - protected string $secret; + protected ?string $secret = null; /** * @var array @@ -59,7 +59,7 @@ public function getId() /** * {@inheritdoc} */ - public function setRandomId($random) + public function setRandomId( string $random ) { $this->randomId = $random; } @@ -67,7 +67,7 @@ public function setRandomId($random) /** * {@inheritdoc} */ - public function getRandomId(): string + public function getRandomId(): ?string { return $this->randomId; } @@ -91,7 +91,7 @@ public function setSecret($secret) /** * {@inheritdoc} */ - public function getSecret(): string + public function getSecret(): ?string { return $this->secret; } diff --git a/Security/Authentication/Token/OAuthToken.php b/Security/Authentication/Token/OAuthToken.php index 2e5979ce..9d00b0d0 100644 --- a/Security/Authentication/Token/OAuthToken.php +++ b/Security/Authentication/Token/OAuthToken.php @@ -25,19 +25,19 @@ class OAuthToken extends AbstractToken /** * @var string */ - protected $token; + protected string $token; - public function setToken($token) + public function setToken(string $token) { $this->token = $token; } - public function getToken() + public function getToken(): string { return $this->token; } - public function getCredentials() + public function getCredentials(): string { return $this->token; } diff --git a/Storage/OAuthStorage.php b/Storage/OAuthStorage.php index 6bf5af03..78760493 100644 --- a/Storage/OAuthStorage.php +++ b/Storage/OAuthStorage.php @@ -58,14 +58,14 @@ class OAuthStorage implements IOAuth2RefreshTokens, IOAuth2GrantUser, IOAuth2Gra protected AuthCodeManagerInterface $authCodeManager; /** - * @var UserProviderInterface + * @var UserProviderInterface|null */ - protected UserProviderInterface $userProvider; + protected ?UserProviderInterface $userProvider; /** - * @var PasswordHasherFactoryInterface + * @var PasswordHasherFactoryInterface|null */ - protected PasswordHasherFactoryInterface $passwordHasherFactory; + protected ?PasswordHasherFactoryInterface $passwordHasherFactory; /** * @var array [uri] => GrantExtensionInterface