Skip to content
This repository was archived by the owner on Jan 30, 2020. It is now read-only.

Commit be4c9b6

Browse files
committed
Merge branch 'fix-case-sensitive-header-handling' of https://github.com/lucian303/zend-http into lucian303-fix-case-sensitive-header-handling
2 parents c3ebd0d + 7ebd945 commit be4c9b6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/Client/Adapter/Curl.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -434,13 +434,13 @@ public function write($method, $uri, $httpVersion = 1.1, $headers = [], $body =
434434

435435
// cURL automatically decodes chunked-messages, this means we have to
436436
// disallow the Zend\Http\Response to do it again.
437-
$responseHeaders = preg_replace("/Transfer-Encoding:\s*chunked\\r\\n/", "", $responseHeaders);
437+
$responseHeaders = preg_replace("/Transfer-Encoding:\s*chunked\\r\\n/i", "", $responseHeaders);
438438

439439
// cURL can automatically handle content encoding; prevent double-decoding from occurring
440440
if (isset($this->config['curloptions'][CURLOPT_ENCODING])
441441
&& '' == $this->config['curloptions'][CURLOPT_ENCODING]
442442
) {
443-
$responseHeaders = preg_replace("/Content-Encoding:\s*gzip\\r\\n/", '', $responseHeaders);
443+
$responseHeaders = preg_replace("/Content-Encoding:\s*gzip\\r\\n/i", '', $responseHeaders);
444444
}
445445

446446
// cURL automatically handles Proxy rewrites, remove the "HTTP/1.0 200 Connection established" string:

0 commit comments

Comments
 (0)