diff options
Diffstat (limited to 'g4f/Provider/needs_auth')
-rw-r--r-- | g4f/Provider/needs_auth/OpenaiChat.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/g4f/Provider/needs_auth/OpenaiChat.py b/g4f/Provider/needs_auth/OpenaiChat.py index b501d655..6601f500 100644 --- a/g4f/Provider/needs_auth/OpenaiChat.py +++ b/g4f/Provider/needs_auth/OpenaiChat.py @@ -572,7 +572,7 @@ this.fetch = async (url, options) => { while headers is None: headers = window.evaluate_js("this._headers") await asyncio.sleep(1) - headers["User-Agent"] = window.evaluate_js("window.navigator.userAgent") + headers["User-Agent"] = window.evaluate_js("this.navigator.userAgent") cookies = [list(*cookie.items()) for cookie in window.get_cookies()] window.destroy() cls._cookies = dict([(name, cookie.value) for name, cookie in cookies]) |