diff --git a/src/Rates.php b/src/Rates.php index cd7ae67..a9d7a7a 100644 --- a/src/Rates.php +++ b/src/Rates.php @@ -38,7 +38,7 @@ class Rates * @param int $refreshInterval How often to check for new VAT rates. Defaults to every 12 hours. * @param Client|null $client The VAT client to use. */ - public function __construct(string $storagePath, int $refreshInterval = 12 * 3600, Client $client = null) + public function __construct(string $storagePath, int $refreshInterval = 12 * 3600, ?Client $client = null) { $this->refreshInterval = $refreshInterval; $this->storagePath = $storagePath; diff --git a/src/Validator.php b/src/Validator.php index fc3e199..2e811dc 100644 --- a/src/Validator.php +++ b/src/Validator.php @@ -55,7 +55,7 @@ class Validator * * @param Vies\Client $client (optional) */ - public function __construct(Vies\Client $client = null) + public function __construct(?Vies\Client $client = null) { $this->client = $client ?: new Vies\Client(); }