Skip to content

Commit 9e89ac4

Browse files
committed
bug #50256 [HttpClient] Fix setting duplicate-name headers when redirecting with AmpHttpClient (nicolas-grekas)
This PR was merged into the 5.4 branch. Discussion ---------- [HttpClient] Fix setting duplicate-name headers when redirecting with AmpHttpClient | Q | A | ------------- | --- | Branch? | 5.4 | Bug fix? | yes | New feature? | no | Deprecations? | no | Tickets | - | License | MIT | Doc PR | - Spotted by `@kelunik` 🙏 Commits ------- 5ff1db081f [HttpClient] Fix setting duplicate-name headers when redirecting with AmpHttpClient
2 parents 514a0f9 + 5d5bfa4 commit 9e89ac4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Response/AmpResponse.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -357,7 +357,7 @@ private static function followRedirects(Request $originRequest, AmpClientState $
357357
}
358358

359359
foreach ($originRequest->getRawHeaders() as [$name, $value]) {
360-
$request->setHeader($name, $value);
360+
$request->addHeader($name, $value);
361361
}
362362

363363
if ($request->getUri()->getAuthority() !== $originRequest->getUri()->getAuthority()) {

0 commit comments

Comments
 (0)