Aggiornato Composer
This commit is contained in:
10
vendor/guzzlehttp/psr7/src/Request.php
vendored
10
vendor/guzzlehttp/psr7/src/Request.php
vendored
@@ -28,7 +28,7 @@ class Request implements RequestInterface
|
||||
/**
|
||||
* @param string $method HTTP method
|
||||
* @param string|UriInterface $uri URI
|
||||
* @param array<string, string|string[]> $headers Request headers
|
||||
* @param (string|string[])[] $headers Request headers
|
||||
* @param string|resource|StreamInterface|null $body Request body
|
||||
* @param string $version Protocol version
|
||||
*/
|
||||
@@ -69,7 +69,7 @@ class Request implements RequestInterface
|
||||
$target = '/';
|
||||
}
|
||||
if ($this->uri->getQuery() != '') {
|
||||
$target .= '?' . $this->uri->getQuery();
|
||||
$target .= '?'.$this->uri->getQuery();
|
||||
}
|
||||
|
||||
return $target;
|
||||
@@ -85,6 +85,7 @@ class Request implements RequestInterface
|
||||
|
||||
$new = clone $this;
|
||||
$new->requestTarget = $requestTarget;
|
||||
|
||||
return $new;
|
||||
}
|
||||
|
||||
@@ -98,6 +99,7 @@ class Request implements RequestInterface
|
||||
$this->assertMethod($method);
|
||||
$new = clone $this;
|
||||
$new->method = strtoupper($method);
|
||||
|
||||
return $new;
|
||||
}
|
||||
|
||||
@@ -131,7 +133,7 @@ class Request implements RequestInterface
|
||||
}
|
||||
|
||||
if (($port = $this->uri->getPort()) !== null) {
|
||||
$host .= ':' . $port;
|
||||
$host .= ':'.$port;
|
||||
}
|
||||
|
||||
if (isset($this->headerNames['host'])) {
|
||||
@@ -141,7 +143,7 @@ class Request implements RequestInterface
|
||||
$this->headerNames['host'] = 'Host';
|
||||
}
|
||||
// Ensure Host is the first header.
|
||||
// See: http://tools.ietf.org/html/rfc7230#section-5.4
|
||||
// See: https://datatracker.ietf.org/doc/html/rfc7230#section-5.4
|
||||
$this->headers = [$header => [$host]] + $this->headers;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user