Skip to content

Commit

Permalink
compatibility with php 8.4
Browse files Browse the repository at this point in the history
  • Loading branch information
liborm85 committed Oct 4, 2024
1 parent 79459f0 commit 62cbfe3
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/Context/InfoContext.php
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ public function __construct(ResponseInterface $response)
/**
* @return mixed
*/
public function getInfo(string $type = null)
public function getInfo(?string $type = null)
{
return $this->response->getInfo($type);
}
Expand Down
2 changes: 1 addition & 1 deletion src/Context/InfoContextInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ interface InfoContextInterface
/**
* @return mixed
*/
public function getInfo(string $type = null);
public function getInfo(?string $type = null);

}
2 changes: 1 addition & 1 deletion src/LoggableHttpClient.php
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ public function request(string $method, string $url, array $options = []): Respo
/**
* @param LoggableResponse|iterable<LoggableResponse> $responses
*/
public function stream($responses, float $timeout = null): ResponseStreamInterface
public function stream($responses, ?float $timeout = null): ResponseStreamInterface
{
if ($responses instanceof LoggableResponse) {
$responses = [$responses];
Expand Down
2 changes: 1 addition & 1 deletion src/Response/LoggableResponse.php
Original file line number Diff line number Diff line change
Expand Up @@ -163,7 +163,7 @@ public function cancel(): void
/**
* @return mixed
*/
public function getInfo(string $type = null)
public function getInfo(?string $type = null)
{
if (null !== $type) {
return $this->info[$type] ?? $this->response->getInfo($type);
Expand Down

0 comments on commit 62cbfe3

Please sign in to comment.