diff --git a/plugins/discourse-local-dates/assets/javascripts/discourse-local-dates.js.no-module.es6 b/plugins/discourse-local-dates/assets/javascripts/discourse-local-dates.js.no-module.es6 index d9c9f138e05..6e4545931f6 100644 --- a/plugins/discourse-local-dates/assets/javascripts/discourse-local-dates.js.no-module.es6 +++ b/plugins/discourse-local-dates/assets/javascripts/discourse-local-dates.js.no-module.es6 @@ -125,6 +125,10 @@ } function _isEqualZones(timezoneA, timezoneB) { + if ((timezoneA || timezoneB) && (!timezoneA || !timezoneB)) { + return false; + } + if (timezoneA.includes(timezoneB) || timezoneB.includes(timezoneA)) { return true; } @@ -250,7 +254,7 @@ timezones.unshift(options.timezone); } - timezones.filter(Boolean).forEach(timezone => { + Array.from(new Set(timezones.filter(Boolean))).forEach(timezone => { if (_isEqualZones(timezone, displayedTimezone)) { return; }