Skip to content

Commit 1b6baa7

Browse files
authored
Merge pull request #623 from nextcloud/backport/621/stable30
[stable30] fix: for transfer encoding causing problems
2 parents 75ad155 + b6fc846 commit 1b6baa7

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

lib/Controller/ExAppProxyController.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -72,6 +72,11 @@ private function createProxyResponse(string $path, IResponse $response, bool $is
7272
}
7373
}
7474

75+
if (isset($responseHeaders['Transfer-Encoding'])
76+
&& str_contains(strtolower($responseHeaders['Transfer-Encoding']), 'chunked')) {
77+
unset($responseHeaders['Transfer-Encoding']);
78+
}
79+
7580
$proxyResponse = new ProxyResponse($response->getStatusCode(), $responseHeaders, $content);
7681
if ($cache && !$isHTML && empty($response->getHeader('cache-control'))
7782
&& $response->getHeader('Content-Type') !== 'application/json'

0 commit comments

Comments
 (0)