From 420dad2af51338c34fbe0e856f5ee10b4e2264ab Mon Sep 17 00:00:00 2001 From: lp177 Date: Tue, 7 Nov 2023 16:03:28 +0100 Subject: [PATCH] Update __init__.py locale.getdefaultlocale() is deprecate, use locale.getlocale() --- undetected_chromedriver/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/undetected_chromedriver/__init__.py b/undetected_chromedriver/__init__.py index d31055a..4bed53a 100644 --- a/undetected_chromedriver/__init__.py +++ b/undetected_chromedriver/__init__.py @@ -360,7 +360,7 @@ class Chrome(selenium.webdriver.chrome.webdriver.WebDriver): try: import locale - language = locale.getdefaultlocale()[0].replace("_", "-") + language = locale.getlocale()[0].replace("_", "-") except Exception: pass if not language: