Skip to content

7.13.0 - #462

Merged
spencermountain merged 11 commits into
masterfrom
dev
Jun 23, 2026
Merged

7.13.0#462
spencermountain merged 11 commits into
masterfrom
dev

Conversation

@spencermountain

Copy link
Copy Markdown
Owner

7.13.0 [Jun 2026]

spencermountain and others added 11 commits May 27, 2026 17:25
add(n, 'month') (and quarter/season/year) clamps an overflowing day to
the length of the target month, but read the static monthLength table
where February is always 28. So Jan 31 + 1 month landed on Feb 28 even
in leap years:

    spacetime('2020-01-31').add(1, 'month')  // Feb 28, expected Feb 29

Route the clamp through the existing leap-aware getMonthLength() helper
(now exported from set/_model.js) so February resolves to 29 in leap
years. Common years are unchanged.
fix(add): clamp month arithmetic to the leap-aware month length
@spencermountain
spencermountain merged commit 33bf957 into master Jun 23, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants