diff --git a/src/Proxy/ProxyExtensions.cs b/src/Proxy/ProxyExtensions.cs index 3628eefc6..5ca6b4f4a 100644 --- a/src/Proxy/ProxyExtensions.cs +++ b/src/Proxy/ProxyExtensions.cs @@ -7,6 +7,7 @@ using System.Threading.Tasks; using Microsoft.AspNetCore.Http; using Microsoft.Extensions.Primitives; +using Microsoft.Net.Http.Headers; namespace Proxy { @@ -118,7 +119,7 @@ public static async Task CopyProxyHttpResponse(this HttpContext context, HttpRes CopyHeaders(responseHeaders, replyMessage.Content.Headers); // SendAsync removes chunking from the response. This removes the header so it doesn't expect a chunked response. - responseHeaders.Remove("transfer-encoding"); + responseHeaders.Remove(HeaderNames.TransferEncoding); using (var responseStream = await replyMessage.Content.ReadAsStreamAsync()) {