This commit is contained in:
2021-08-30 14:58:00 +08:00
parent c843b47425
commit f63d66fbda
+3
View File
@@ -223,6 +223,9 @@ class Uri implements UriInterface
$header = $request->header;
$uri = new Uri();
$uri = $uri->withScheme(!empty($server['https']) && $server['https'] !== 'off' ? 'https' : 'http');
if (isset($request->header['x-forwarded-proto'])) {
$uri->withScheme($request->header['x-forwarded-proto']);
}
$hasPort = false;
if (isset($server['http_host'])) {