Skip to content

Commit

Permalink
fix: automatic year increment
Browse files Browse the repository at this point in the history
  • Loading branch information
DenisVorop committed Jan 9, 2024
1 parent b1a4a68 commit 05ec9d3
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/utils/dateTime.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ test('returns lastDayOfQuarter for en locale', () => {
});

test('returns available years for passed number', () => {
expect(getAvailableYears(6)).toStrictEqual([2023, 2024, 2025, 2026, 2027, 2028]);
const currentYear = new Date().getFullYear();
expect(getAvailableYears(6)).toStrictEqual(Array.from({ length: 6 }).map((_, index) => currentYear + index));
});

describe('increment year if the date has passed', () => {
Expand Down
2 changes: 1 addition & 1 deletion src/utils/worker/mail/templates.ts
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ const notice = "_NB: you got this email because you're the owner/issuer/partici
const footer = `
____
© 2023 Taskany inc.
© ${new Date().getFullYear()} Taskany inc.
`;

interface GoalCommentedEmailProps {
Expand Down

0 comments on commit 05ec9d3

Please sign in to comment.