Update cacher.go

This commit is contained in:
Mehdi Osman 2022-04-28 15:50:36 +02:00 committed by GitHub
parent b473f5e425
commit b544544492
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -61,7 +61,7 @@ func (c *cacher) cacheURL(requestURL string, sessionID uint64, depth byte, conte
}
req, _ := http.NewRequest("GET", requestURL, nil)
req.Header.Set("Cookie", "ABv=3;") // Hack for rueducommerce
req.Header.Set("Cookie", "ABv=3;")
req.Header.Set("User-Agent", "Mozilla/5.0 (Windows NT 6.1; rv:31.0) Gecko/20100101 Firefox/31.0")
res, err := c.httpClient.Do(req)
if err != nil {
@ -92,7 +92,7 @@ func (c *cacher) cacheURL(requestURL string, sessionID uint64, depth byte, conte
strData := string(data)
if isCSS {
strData = c.rewriter.RewriteCSS(sessionID, requestURL, strData) // TODO: one method for reqrite and return list
strData = c.rewriter.RewriteCSS(sessionID, requestURL, strData) // TODO: one method for rewrite and return list
}
// TODO: implement in streams