From 16eac5040b31fa5fdbb1637c01651c543a1d4d08 Mon Sep 17 00:00:00 2001 From: Abe Jellinek Date: Tue, 22 Nov 2022 20:53:13 -0500 Subject: [PATCH] fx-compat: Fix error when switching language to Automatic Services.locale always wants an array now, but it can be empty. We still get "Uncaught (in promise) undefined" printed to the console, no stack, not caught by "Pause on exceptions" in the debugger... but it's not clear that that's actually coming from this code, and it doesn't seem to prevent anything from working. --- chrome/content/zotero/preferences/preferences_general.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/chrome/content/zotero/preferences/preferences_general.js b/chrome/content/zotero/preferences/preferences_general.js index 63b554bca0..8b53513ebd 100644 --- a/chrome/content/zotero/preferences/preferences_general.js +++ b/chrome/content/zotero/preferences/preferences_general.js @@ -102,7 +102,7 @@ Zotero_Preferences.General = { var changed = requestedLocale && requestedLocale == Zotero.locale && menu.label != this._getAutomaticLocaleMenuLabel(); - Services.locale.requestedLocales = null; + Services.locale.requestedLocales = []; } else { // Changed if moving to a locale other than the current one