More user agent fixes

This commit is contained in:
Zed 2019-12-08 13:45:35 +01:00
parent 7863fe314e
commit 336cd6125c

View file

@ -103,12 +103,15 @@ proc os(): string =
&"({os}{rv()})"
proc browser(os: string; prod: string): string =
if "Opera" in os:
if "Opera" in prod:
if rand(1) == 0: return presto()
else: return appleWebKit() & chrome() & safari() & opr()
if "X11" in os and "rv" notin os:
return appleWebKit() & chrome() & safari()
let r = rand(100)
if r < 10: "like Gecko"
if r < 5: "like Gecko"
elif r < 50: appleWebKit() & chrome() & safari()
else: firefox()