diff --git a/Sms77Transport.php b/Sms77Transport.php index 6761ec1..372ec2a 100644 --- a/Sms77Transport.php +++ b/Sms77Transport.php @@ -31,7 +31,7 @@ final class Sms77Transport extends AbstractTransport private string $apiKey; private ?string $from; - public function __construct(#[\SensitiveParameter] string $apiKey, string $from = null, HttpClientInterface $client = null, EventDispatcherInterface $dispatcher = null) + public function __construct(#[\SensitiveParameter] string $apiKey, ?string $from = null, ?HttpClientInterface $client = null, ?EventDispatcherInterface $dispatcher = null) { $this->apiKey = $apiKey; $this->from = $from; diff --git a/Tests/Sms77TransportTest.php b/Tests/Sms77TransportTest.php index 3c46483..0a1ad1f 100644 --- a/Tests/Sms77TransportTest.php +++ b/Tests/Sms77TransportTest.php @@ -21,7 +21,7 @@ final class Sms77TransportTest extends TransportTestCase { - public static function createTransport(HttpClientInterface $client = null, string $from = null): Sms77Transport + public static function createTransport(?HttpClientInterface $client = null, ?string $from = null): Sms77Transport { return new Sms77Transport('apiKey', $from, $client ?? new MockHttpClient()); }