Skip to content

Commit

Permalink
Improve typing in ServerRequestFactory::getHeaderFromArray()
Browse files Browse the repository at this point in the history
Signed-off-by: Tim Düsterhus <duesterhus@woltlab.com>
  • Loading branch information
TimWolla authored and Ocramius committed Jul 6, 2022
1 parent 8366949 commit 79ecff2
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/ServerRequestFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -289,9 +289,10 @@ private static function marshalHostAndPortFromHeader($host): array
/**
* Retrieve a header value from an array of headers using a case-insensitive lookup.
*
* @template T
* @param array<string, string|list<string>> $headers Key/value header pairs
* @param mixed $default Default value to return if header not found
* @return mixed
* @param T $default Default value to return if header not found
* @return string|T
*/
private static function getHeaderFromArray(string $name, array $headers, $default = null)
{
Expand Down

0 comments on commit 79ecff2

Please sign in to comment.