From f5089a0b0e9e7d289d190475891e76dbe6ba6eca Mon Sep 17 00:00:00 2001 From: Goffin Simon Date: Wed, 10 Jun 2020 10:42:21 +0000 Subject: [PATCH] [FIX] odoo: Traceback when creating a new contact Steps to reproduce the bug: - Let's consider a new instance with default installed language 'en_US' - Install CRM - Activate a second language (e.g. en_GB) - Set that language in all users - Inactivate default language 'en_US' - Reset the language of your current user (no value) - Go to contact and try to create a new one Bug: A traceback was raised because the lang en_US did not exist. opw:2267711 closes odoo/odoo#53064 X-original-commit: c43647f085a7f62c9c81db6553be6a6e402943d0 Signed-off-by: Simon Goffin (sig) --- odoo/http.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/odoo/http.py b/odoo/http.py index 1a494be1fa3..4d2df076032 100644 --- a/odoo/http.py +++ b/odoo/http.py @@ -1071,7 +1071,7 @@ class OpenERPSession(sessions.Session): if lang in babel.core.LOCALE_ALIASES: lang = babel.core.LOCALE_ALIASES[lang] - context['lang'] = lang or 'en_US' + context['lang'] = lang def save_action(self, action): """