diff --git a/src/Rest/HttpExchangeFormatter.php b/src/Rest/HttpExchangeFormatter.php index f4cee95..d757089 100644 --- a/src/Rest/HttpExchangeFormatter.php +++ b/src/Rest/HttpExchangeFormatter.php @@ -11,7 +11,7 @@ class HttpExchangeFormatter private $response; - public function __construct(RequestInterface $request = null, ResponseInterface $response = null) + public function __construct(?RequestInterface $request = null, ?ResponseInterface $response = null) { $this->request = $request; $this->response = $response; diff --git a/src/Rest/RestApiBrowser.php b/src/Rest/RestApiBrowser.php index 60143bc..406016c 100644 --- a/src/Rest/RestApiBrowser.php +++ b/src/Rest/RestApiBrowser.php @@ -40,7 +40,7 @@ class RestApiBrowser /** * @param string $host */ - public function __construct($host, ClientInterface $httpClient = null) + public function __construct($host, ?ClientInterface $httpClient = null) { $this->host = $host; $this->httpClient = $httpClient ?: Psr18ClientDiscovery::find();