Skip to content

Commit 8431435

Browse files
Add return type unions to private/internal/final/test methods
1 parent e77c0f3 commit 8431435

File tree

1 file changed

+1
-13
lines changed

1 file changed

+1
-13
lines changed

Response.php

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -54,11 +54,6 @@ public function __toString(): string
5454
return $headers."\n".$this->content;
5555
}
5656

57-
/**
58-
* Gets the response content.
59-
*
60-
* @return string The response content
61-
*/
6257
public function getContent(): string
6358
{
6459
return $this->content;
@@ -69,22 +64,15 @@ public function getStatusCode(): int
6964
return $this->status;
7065
}
7166

72-
/**
73-
* Gets the response headers.
74-
*
75-
* @return array The response headers
76-
*/
7767
public function getHeaders(): array
7868
{
7969
return $this->headers;
8070
}
8171

8272
/**
83-
* Gets a response header.
84-
*
8573
* @return string|array|null The first header value if $first is true, an array of values otherwise
8674
*/
87-
public function getHeader(string $header, bool $first = true)
75+
public function getHeader(string $header, bool $first = true): string|array|null
8876
{
8977
$normalizedHeader = str_replace('-', '_', strtolower($header));
9078
foreach ($this->headers as $key => $value) {

0 commit comments

Comments
 (0)