From 237640f0d73eec356cbcb6bbd9645b320b9873d7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stefan=20B=C3=BChler?= Date: Thu, 7 Apr 2022 14:59:14 +0200 Subject: [PATCH] fix resetting session lang if unset --- src/capport/api/lang.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/capport/api/lang.py b/src/capport/api/lang.py index e3c1911..3ff3e99 100644 --- a/src/capport/api/lang.py +++ b/src/capport/api/lang.py @@ -60,7 +60,7 @@ def detect_language(): return else: # reset language - s.pop('lang') + s.pop('lang', None) lang = s.get('lang') if lang: lang = lang.strip().lower()