From 234832d1f0b739a925534163bb3c6aea91ac1699 Mon Sep 17 00:00:00 2001 From: Nathan Gray Date: Tue, 12 Jun 2012 18:47:42 +0000 Subject: [PATCH] Make sure lang 'array' is not a real array - that means it's empty, and will return 0 for missing translations. It is supposed to be an object. --- phpgwapi/js/jsapi/egw_lang.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/phpgwapi/js/jsapi/egw_lang.js b/phpgwapi/js/jsapi/egw_lang.js index 691b32e571..d8ac45e454 100644 --- a/phpgwapi/js/jsapi/egw_lang.js +++ b/phpgwapi/js/jsapi/egw_lang.js @@ -37,7 +37,10 @@ egw.extend('lang', egw.MODULE_GLOBAL, function() { */ set_lang_arr: function(_app, _messages) { - lang_arr[_app] = _messages; + if(!jQuery.isArray(_messages)) + { + lang_arr[_app] = _messages; + } }, /**