[FIX] bootstrap_translations: leftover handling for multiple langs caused error if preferred lang had a hyphen

bzr revid: odo@openerp.com-20121004091314-13nbs4386fimlxd3
This commit is contained in:
Olivier Dony
2012-10-04 11:13:14 +02:00
parent ba97319054
commit bc650ac97c
+1 -1
View File
@@ -685,7 +685,7 @@ class WebClient(openerpweb.Controller):
# sub-languages (that should only be partially translated) we load the
# main language PO instead - that should be enough for the login screen.
if '-' in lang: # RFC2616 uses '-' separators for sublanguages
lang = [lang.split('-',1)[0], lang]
lang = lang.split('-')[0]
translations_per_module = {}
for addon_name in mods: