refactoring

This commit is contained in:
y a t s
2026-06-19 10:42:39 -04:00
parent 74b923f06f
commit c7ccfc65bf
3 changed files with 25 additions and 33 deletions
+2 -4
View File
@@ -13,13 +13,11 @@ import (
gq "github.com/PuerkitoBio/goquery"
)
const _USER_AGENT = "Mozilla/5.0 (Windows NT 6.1; rv:60.0) Gecko/20100101 Firefox/60.0"
type KF struct {
client http.Client
domain *url.URL
Cookies jar
Cookies cookieJar
}
// Supply your own http.Client to route through any proxies.
@@ -41,7 +39,7 @@ func NewKF(hc http.Client, host *url.URL) (KF, error) {
return KF{
client: hc,
domain: u,
Cookies: jar{hc.Jar},
Cookies: cookieJar{&hc.Jar},
}, nil
}