We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 7c71ff0 commit 5d88fcfCopy full SHA for 5d88fcf
src/RedirectClientDecorator.php
@@ -43,6 +43,9 @@ public function sendRequest(RequestInterface $request): ResponseInterface
43
$userInfo = $url['user'] . $url['pass'] ? ':' . $url['pass'] : '';
44
if (array_key_exists('scheme', $url) && $url['scheme'] !== $uri->getScheme()) {
45
$uri = $uri->withScheme($url['scheme']);
46
+ if (!array_key_exists('port', $url)) {
47
+ $url['port'] = $url['scheme'] === 'https' ? 443 : 80;
48
+ }
49
}
50
if ($uri->getUserInfo() !== $userInfo) {
51
$uri = $uri->withUserInfo($userInfo);
0 commit comments