Skip to content

Commit

Permalink
fix: reduce bundle size even more
Browse files Browse the repository at this point in the history
  • Loading branch information
khawarizmus authored and justingrant committed May 29, 2024
1 parent 008e4b7 commit 26e4ceb
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions polyfill/lib/calendar.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -1323,12 +1323,10 @@ const helperIslamic = ObjectAssign({}, nonIsoHelperBase, {
DAYS_PER_ISO_YEAR: 365.2425,
constantEra: 'ah',
reviseIntlEra(calendarDate /*, isoDate*/) {
let { era, eraYear } = calendarDate;
// Chrome for Android as of v 142.0.6367.179 mishandled the era option in Intl.DateTimeFormat
// and returned 'bc' instead of 'ah'. This code corrects that and any possible future errors.
// see https://issues.chromium.org/issues/40856332
era = 'ah';
return { era, eraYear };
return { ...calendarDate, era: 'ah' };
},
estimateIsoDate(calendarDate) {
const { year } = this.adjustCalendarDate(calendarDate);
Expand Down

0 comments on commit 26e4ceb

Please sign in to comment.