Skip to content

Commit 64eb668

Browse files
committed
fix(docs): should count any range between Jan & Dec
1 parent fdb1953 commit 64eb668

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/.vitepress/composables/date.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ export function isBetweenHalloweenAndHalfOfNovember(date: Date) {
1111
export function isBetweenChristmasAndHalfOfJanuary(date: Date) {
1212
const year = date.getFullYear()
1313
const christmas = new Date(year, 11, 20) // December 20
14-
const halfOfJanuary = new Date(year + 1, 0, 10) // January 10 of the next year
14+
const halfOfJanuary = new Date(year, 0, 10) // January 10 of the next year
1515

1616
return isAfter(date, christmas) && isBefore(date, halfOfJanuary)
1717
}

0 commit comments

Comments
 (0)