Skip to content

Commit b3e9f57

Browse files
authored
Merge pull request #67 from ruudk/patch-1
Make compatible with PHP 8.4
2 parents e6d5d9b + 37e533b commit b3e9f57

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Client.php

+2-2
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ public function addException(\Exception $exception)
204204
*
205205
* If both a default exception and a default response are set, the exception will be thrown.
206206
*/
207-
public function setDefaultException(\Exception $defaultException = null)
207+
public function setDefaultException(?\Exception $defaultException = null)
208208
{
209209
if (null !== $defaultException && !$defaultException instanceof Exception) {
210210
@trigger_error('Clients may only throw exceptions of type '.Exception::class.'. Setting an exception of class '.get_class($defaultException).' will not be possible anymore in the future', E_USER_DEPRECATED);
@@ -223,7 +223,7 @@ public function addResponse(ResponseInterface $response)
223223
/**
224224
* Sets the default response to be returned when the list of added exceptions and responses is exhausted.
225225
*/
226-
public function setDefaultResponse(ResponseInterface $defaultResponse = null)
226+
public function setDefaultResponse(?ResponseInterface $defaultResponse = null)
227227
{
228228
$this->defaultResponse = $defaultResponse;
229229
}

0 commit comments

Comments
 (0)