Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: first and last week of month and year #10

Merged
merged 1 commit into from
Jun 28, 2021

Conversation

scroskey-clinc
Copy link

@scroskey-clinc scroskey-clinc commented Jun 15, 2021

Fixes Time rules for the first/last week of a month/year. Previously, these rules would return the gregorian definition of first/last which in some cases excludes the first or last day of the month/year.

Examples:

  • the first week of 2020
  • the second to last week of july
  • last monday of 2021
  • last week of october
  • the week of october 6th

Copy link

@RajanMehtaClinc RajanMehtaClinc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've validated all the rules and they work as expected.

Just one exception:
week of october 6th doesn't work.
the week of october 6th works fine.

Approving the PR as it is safe to backlog the above issue

@clinc clinc deleted a comment from RajanMehta Jun 28, 2021
@clinc clinc deleted a comment from RajanMehta Jun 28, 2021
@scroskey-clinc scroskey-clinc merged commit 4c04a18 into master Jun 28, 2021
@scroskey-clinc scroskey-clinc deleted the sean/first-last-week branch June 28, 2021 17:04
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.

3 participants