From 403b5ddd1360e1d9b7a4cd41026b3112b4ff18d9 Mon Sep 17 00:00:00 2001 From: 4shadoww <4shadoww0@gmail.com> Date: Thu, 31 May 2018 14:12:39 +0300 Subject: [PATCH] added new test to check is locale defined --- bumblebee/modules/datetime.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/bumblebee/modules/datetime.py b/bumblebee/modules/datetime.py index a46ab67..ffd0b0d 100644 --- a/bumblebee/modules/datetime.py +++ b/bumblebee/modules/datetime.py @@ -32,7 +32,7 @@ class Module(bumblebee.engine.Module): bumblebee.output.Widget(full_text=self.get_time)) self._fmt = self.parameter("format", default_format(self.name)) l = locale.getdefaultlocale() - if not l: + if not l or l == (None, None): l = ('en_US', 'UTF-8') lcl = self.parameter("locale", ".".join(l)) locale.setlocale(locale.LC_TIME, lcl.split("."))