Skip to content

Commit 713e3c2

Browse files
committed
Fix: Support for Chrome < 91
1 parent 1323fd3 commit 713e3c2

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

js/src/util/calendar.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -812,13 +812,13 @@ export const getMonthDetails = (year, month, firstDayOfWeek) => {
812812

813813
if ((index + 1) % 7 === 0) {
814814
const { weekNumber, year } = getISOWeekNumberAndYear(day.date)
815-
const lastWeek = weeks.at(-1)
815+
const lastWeek = weeks[weeks.length - 1]
816816
if (lastWeek) {
817817
lastWeek.week = { number: weekNumber, year }
818818
}
819819
}
820820

821-
const lastWeek = weeks.at(-1)
821+
const lastWeek = weeks[weeks.length - 1]
822822
if (lastWeek) {
823823
lastWeek.days.push(day)
824824
}

0 commit comments

Comments
 (0)