(targetMonthIndex: number)
| 602 | const currentMonth = current.getUTCMonth() + 1 |
| 603 | const nextMonth = table.month[currentMonth] |
| 604 | const clampBoundaryDay = (targetMonthIndex: number): number => { |
| 605 | if (cron.days.size !== 0) { |
| 606 | return boundary.day |
| 607 | } |
| 608 | const maxDayInMonth = daysInMonth(new Date(Date.UTC(current.getUTCFullYear(), targetMonthIndex, 1))) |
| 609 | return Math.min(boundary.day, maxDayInMonth) |
| 610 | } |
| 611 | if (nextMonth === undefined) { |
| 612 | current.setUTCFullYear(current.getUTCFullYear() + tick) |
| 613 | current.setUTCMonth(boundary.month, clampBoundaryDay(boundary.month)) |
no test coverage detected