diff --git a/python_apps/media-monitor/media_monitor.py b/python_apps/media-monitor/media_monitor.py index 2a4558191..024b5ae41 100644 --- a/python_apps/media-monitor/media_monitor.py +++ b/python_apps/media-monitor/media_monitor.py @@ -49,7 +49,7 @@ def configure_locale(): new_locale = default_locale test = re.compile(r"UTF-?8", re.IGNORECASE) - if re.findall(new_locale): + if test.findall(new_locale): logger.info("New locale set to: %s", locale.setlocale(locale.LC_ALL, new_locale)) else: logger.info("Invalid locale %s", new_locale) diff --git a/python_apps/pypo/pypocli.py b/python_apps/pypo/pypocli.py index b1c58fc88..0f804fd30 100644 --- a/python_apps/pypo/pypocli.py +++ b/python_apps/pypo/pypocli.py @@ -72,7 +72,7 @@ def configure_locale(): new_locale = default_locale test = re.compile(r"UTF-?8", re.IGNORECASE) - if re.findall(new_locale): + if test.findall(new_locale): logger.info("New locale set to: %s", locale.setlocale(locale.LC_ALL, new_locale)) else: logger.info("Invalid locale %s", new_locale)