UI: Fix localization fn override

If localization function is specified in another plugin, do not use the
default
This commit is contained in:
Brian Federle 2013-07-10 11:16:18 -07:00
parent 7ce0bd69a8
commit 37ba08a8ea
1 changed files with 5 additions and 3 deletions

View File

@ -483,9 +483,11 @@
cloudStack.uiCustom.login(loginArgs);
// Localization
cloudStack.localizationFn = function(str) {
return dictionary[str];
};
if (!$.isFunction(cloudStack.localizationFn)) { // i.e., localize is overridden by a plugin/module
cloudStack.localizationFn = function(str) {
return dictionary[str];
};
}
document.title = _l('label.app.name');
});