diff --git a/packages/backend/src/helpers/webhook-handler-sync.js b/packages/backend/src/helpers/webhook-handler-sync.js index f7c40642..9f33f121 100644 --- a/packages/backend/src/helpers/webhook-handler-sync.js +++ b/packages/backend/src/helpers/webhook-handler-sync.js @@ -63,6 +63,8 @@ export default async (flowId, request, response) => { }); if (testRun) { + response.status(204).end(); + // in case of testing, we do not process the whole process. continue; } @@ -74,6 +76,12 @@ export default async (flowId, request, response) => { executionId, }); + if (actionStep.appKey === 'filter' && !actionExecutionStep.dataOut) { + response.status(422).end(); + + break; + } + if (actionStep.key === 'respondWith' && !response.headersSent) { const { headers, statusCode, body } = actionExecutionStep.dataOut;