Update user agent handling

This commit is contained in:
pluja 2023-11-12 22:13:58 +01:00
parent c91f0b4613
commit 25e4493631

View File

@ -35,11 +35,10 @@ func GetBodyHtml(url string) (string, error) {
s := rand.NewSource(time.Now().UnixNano())
r := rand.New(s)
userAgent := userAgents[r.Intn(len(userAgents))]
req.Header.Set(
"User-Agent",
userAgent,
userAgents[r.Intn(len(userAgents))],
)
req.Header.Set(
"Accept",