From c895f4cbf4f279e54e69820731b0989e9509a57f Mon Sep 17 00:00:00 2001 From: Shireen Missi <94372015+ShireenMissi@users.noreply.github.com> Date: Thu, 5 Sep 2024 17:52:51 +0100 Subject: [PATCH] fix: Fix the issue in Trigger Nodes where poll time was not loaded (#10695) Co-authored-by: Elias Meire Co-authored-by: Oleg Ivaniv --- packages/cli/src/node-types.ts | 4 ++-- packages/workflow/src/NodeHelpers.ts | 7 ------- 2 files changed, 2 insertions(+), 9 deletions(-) diff --git a/packages/cli/src/node-types.ts b/packages/cli/src/node-types.ts index 550b836a16c668..baf828ac377066 100644 --- a/packages/cli/src/node-types.ts +++ b/packages/cli/src/node-types.ts @@ -74,8 +74,8 @@ export class NodeTypes implements INodeTypes { if (type in knownNodes) { const { className, sourcePath } = knownNodes[type]; - const loaded: INodeType | IVersionedNodeType = loadClassInIsolation(sourcePath, className); - if (NodeHelpers.isINodeType(loaded)) NodeHelpers.applySpecialNodeParameters(loaded); + const loaded: INodeType = loadClassInIsolation(sourcePath, className); + NodeHelpers.applySpecialNodeParameters(loaded); loadedNodes[type] = { sourcePath, type: loaded }; return loadedNodes[type]; diff --git a/packages/workflow/src/NodeHelpers.ts b/packages/workflow/src/NodeHelpers.ts index 1a58de2302a3a3..9e68a03a8088ae 100644 --- a/packages/workflow/src/NodeHelpers.ts +++ b/packages/workflow/src/NodeHelpers.ts @@ -352,13 +352,6 @@ const declarativeNodeOptionParameters: INodeProperties = { ], }; -/** - * Determines if the node is of INodeType - */ -export function isINodeType(obj: unknown): obj is INodeType { - return typeof obj === 'object' && obj !== null && 'execute' in obj; -} - /** * Modifies the description of the passed in object, such that it can be used * as an AI Agent Tool.