fix(core): Fix expressions in webhook nodes(Form, Webhook) to access previous node's data (#10247)

Co-authored-by: कारतोफ्फेलस्क्रिप्ट™ <aditya@netroy.in>
This commit is contained in:
Michael Kret
2024-08-01 11:21:58 +03:00
committed by GitHub
parent 1608d2527b
commit 88a170176a
4 changed files with 26 additions and 6 deletions

View File

@@ -466,6 +466,7 @@ export interface IGetExecuteWebhookFunctions {
mode: WorkflowExecuteMode,
webhookData: IWebhookData,
closeFunctions: CloseFunction[],
runExecutionData: IRunExecutionData | null,
): IWebhookFunctions;
}

View File

@@ -1237,6 +1237,7 @@ export class Workflow {
additionalData: IWorkflowExecuteAdditionalData,
nodeExecuteFunctions: INodeExecuteFunctions,
mode: WorkflowExecuteMode,
runExecutionData: IRunExecutionData | null,
): Promise<IWebhookResponseData> {
const nodeType = this.nodeTypes.getByNameAndVersion(node.type, node.typeVersion);
if (nodeType === undefined) {
@@ -1258,6 +1259,7 @@ export class Workflow {
mode,
webhookData,
closeFunctions,
runExecutionData,
);
return nodeType instanceof Node
? await nodeType.webhook(context)