]> 127.0.0.1 Git - part/.git/commitdiff
102 v0.3.6
authorqydysky <qydysky@foxmail.com>
Sat, 23 Jan 2021 12:17:50 +0000 (20:17 +0800)
committerqydysky <qydysky@foxmail.com>
Sat, 23 Jan 2021 12:17:50 +0000 (20:17 +0800)
Reqf.go

diff --git a/Reqf.go b/Reqf.go
index 53d4b35b636e69a054aa4f070333f6c616cf2e4e..872f0127a6f3513469802d23f67a595a5b46a906 100644 (file)
--- a/Reqf.go
+++ b/Reqf.go
@@ -136,6 +136,7 @@ func (this *req) Reqf_1(val Rval) (error) {
     if _,ok := Header["Accept"];!ok {Header["Accept"] = `text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8`}
     if _,ok := Header["Connection"];!ok {Header["Connection"] = "keep-alive"}
     if _,ok := Header["Accept-Encoding"];!ok {Header["Accept-Encoding"] = "gzip, deflate, br"}
+    if SaveToPath != "" {Header["Accept-Encoding"] = "identity"}
     if _,ok := Header["User-Agent"];!ok {Header["User-Agent"] = "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/75.0.3770.142 Safari/537.36"}
 
     for k,v := range Header {