From 33d3e5c75349c621b4548a01ebc275fcad69726d Mon Sep 17 00:00:00 2001 From: Raphael Michel Date: Mon, 30 May 2016 22:16:03 +0200 Subject: [PATCH] Fixed problems when running the Django shell --- src/pretix/base/i18n.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/pretix/base/i18n.py b/src/pretix/base/i18n.py index b9c117bed..d5901ccb2 100644 --- a/src/pretix/base/i18n.py +++ b/src/pretix/base/i18n.py @@ -43,7 +43,7 @@ class LazyI18nString: the string in the system's default language. If this is unavailable as well, it will give you the string in the first language available. """ - return self.localize(translation.get_language()) + return self.localize(translation.get_language() or settings.LANGUAGE_CODE) def __bool__(self): if not self.data: