Fix Firefox 55 breakage (and remove unnecessary locale lookups)
We were manually looking up the current locale in various places and passing it to nsIStringBundleService::createBundle(), but that hasn't even been a supported argument for years. (I assume it was a long time ago?)
This commit is contained in:
parent
59edca783e
commit
55b2dc39bf
5 changed files with 32 additions and 64 deletions
|
@ -378,18 +378,10 @@ function ZoteroService() {
|
|||
let quitStr = "Quit";
|
||||
let checkForUpdateStr = "Check for Update";
|
||||
try {
|
||||
let appLocale;
|
||||
if (Services.locale.getAppLocale) {
|
||||
appLocale = Services.locale.getAppLocale();
|
||||
}
|
||||
// Fx <=53
|
||||
else {
|
||||
appLocale = Services.locale.getApplicationLocale();
|
||||
}
|
||||
let src = 'chrome://zotero/locale/zotero.properties';
|
||||
let stringBundleService = Components.classes["@mozilla.org/intl/stringbundle;1"]
|
||||
.getService(Components.interfaces.nsIStringBundleService);
|
||||
let stringBundle = stringBundleService.createBundle(src, appLocale);
|
||||
let stringBundle = stringBundleService.createBundle(src);
|
||||
errorStr = stringBundle.GetStringFromName('general.error');
|
||||
checkForUpdateStr = stringBundle.GetStringFromName('general.checkForUpdate');
|
||||
quitStr = stringBundle.GetStringFromName('general.quit');
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue