Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8281fe4 commit 3f6c3b4Copy full SHA for 3f6c3b4
1 file changed
lib/request/connect.py
@@ -332,7 +332,9 @@ def getPage(**kwargs):
332
if HTTP_HEADER.ACCEPT not in headers:
333
headers[HTTP_HEADER.ACCEPT] = HTTP_ACCEPT_HEADER_VALUE
334
335
- headers[HTTP_HEADER.ACCEPT_ENCODING] = HTTP_ACCEPT_ENCODING_HEADER_VALUE if kb.pageCompress else "identity"
+ if HTTP_HEADER.ACCEPT_ENCODING not in headers:
336
+ headers[HTTP_HEADER.ACCEPT_ENCODING] = HTTP_ACCEPT_ENCODING_HEADER_VALUE if kb.pageCompress else "identity"
337
+
338
headers[HTTP_HEADER.HOST] = host or getHostHeader(url)
339
340
if post is not None and HTTP_HEADER.CONTENT_TYPE not in headers:
0 commit comments