diff --git a/chrome/content/zotero/elements/styleConfigurator.js b/chrome/content/zotero/elements/styleConfigurator.js index 278a0a4f0d..4e950fca36 100644 --- a/chrome/content/zotero/elements/styleConfigurator.js +++ b/chrome/content/zotero/elements/styleConfigurator.js @@ -107,6 +107,15 @@ } set value(val) { + try { + // eslint-disable-next-line no-new + new Intl.Locale(val); + } + catch (e) { + Zotero.logError(e); + val = ''; + } + this._value = val; const styleData = this._style ? Zotero.Styles.get(this._style) : null; this.localeListEl.value = styleData && styleData.locale || this._value;