Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit bc25829

Browse files
Don't normalize query string in PsrHttpFactory
1 parent 1309b64 commit bc25829

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

CHANGELOG.md

+6
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,12 @@
11
CHANGELOG
22
=========
33

4+
# 2.0.1 (2020-06-25)
5+
6+
* Don't normalize query string in PsrHttpFactory
7+
* Fix conversion for HTTPS requests
8+
* Fix populating default port and headers in HttpFoundationFactory
9+
410
# 2.0.0 (2020-01-02)
511

612
* Remove DiactorosFactory

Factory/PsrHttpFactory.php

+4-1
Original file line numberDiff line numberDiff line change
@@ -48,9 +48,12 @@ public function __construct(ServerRequestFactoryInterface $serverRequestFactory,
4848
*/
4949
public function createRequest(Request $symfonyRequest)
5050
{
51+
$uri = $symfonyRequest->server->get('QUERY_STRING', '');
52+
$uri = $symfonyRequest->getSchemeAndHttpHost().$symfonyRequest->getBaseUrl().$symfonyRequest->getPathInfo().('' !== $uri ? '?'.$uri : '');
53+
5154
$request = $this->serverRequestFactory->createServerRequest(
5255
$symfonyRequest->getMethod(),
53-
$symfonyRequest->getUri(),
56+
$uri,
5457
$symfonyRequest->server->all()
5558
);
5659

0 commit comments

Comments
 (0)