Skip to content

Commit

Permalink
fix(Schedule Trigger Node): Use the correct moment import (#8185)
Browse files Browse the repository at this point in the history
Any node that uses `moment.tz` should import from `moment-timezone`
instead of `moment`.

This fixes #8184
  • Loading branch information
netroy authored and ivov committed Jan 3, 2024
1 parent d52de81 commit f8307dc
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/nodes-base/nodes/Schedule/GenericFunctions.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import type { IDataObject } from 'n8n-workflow';
import moment from 'moment';
import moment from 'moment-timezone';
import type { IRecurencyRule } from './SchedulerInterface';

export function recurencyCheck(
Expand Down
2 changes: 1 addition & 1 deletion packages/nodes-base/nodes/Schedule/ScheduleTrigger.node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import type {
import { NodeOperationError } from 'n8n-workflow';

import { CronJob } from 'cron';
import moment from 'moment';
import moment from 'moment-timezone';
import type { IRecurencyRule } from './SchedulerInterface';
import { convertToUnixFormat, recurencyCheck } from './GenericFunctions';

Expand Down

0 comments on commit f8307dc

Please sign in to comment.