We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent a733263 commit df49b6fCopy full SHA for df49b6f
src/Providers/Http/HttpTransporter.php
@@ -115,14 +115,11 @@ private function convertToPsr7Request(Request $request): RequestInterface
115
*/
116
private function convertFromPsr7Response(ResponseInterface $psr7Response): Response
117
{
118
- /** @var array<string, string|list<string>> $headers */
119
- $headers = [];
120
- foreach ($psr7Response->getHeaders() as $name => $values) {
121
- $headers[(string) $name] = count($values) === 1 ? $values[0] : array_values($values);
122
- }
123
-
124
$body = (string) $psr7Response->getBody();
125
+ /** @var array<string, array<string>> $headers */
+ $headers = $psr7Response->getHeaders();
+
126
return new Response(
127
$psr7Response->getStatusCode(),
128
$headers,
0 commit comments