Be a bit more helpful when calling getString() on a string with no localization
This commit is contained in:
parent
4242c62b1b
commit
031d78eeee
1 changed files with 7 additions and 1 deletions
|
@ -156,7 +156,13 @@ var Scholar = new function(){
|
|||
|
||||
|
||||
function getString(name){
|
||||
return _localizedStringBundle.GetStringFromName(name);
|
||||
try {
|
||||
var l10n = _localizedStringBundle.GetStringFromName(name);
|
||||
}
|
||||
catch (e){
|
||||
throw ('Localized string not available for ' + name);
|
||||
}
|
||||
return l10n;
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in a new issue