diff --git a/src/lib/processors/mutate-processor.ts b/src/lib/processors/mutate-processor.ts index 4d1788be..29a656f6 100644 --- a/src/lib/processors/mutate-processor.ts +++ b/src/lib/processors/mutate-processor.ts @@ -186,6 +186,7 @@ export async function mutateProcessor( for (const bindable of bindables) { ({ wrapped, response } = await processRequest(bindable, wrapped, response)); if (config.onError === OnError.REJECT && response?.warnings!.length > 0) { + webhookTimer.stop(); return response; } } @@ -196,11 +197,13 @@ export async function mutateProcessor( // If no capability matched the request, exit early if (bindables.length === 0) { Log.info(reqMetadata, `No matching actions found`); + webhookTimer.stop(); return response; } // delete operations can't be mutate, just return before the transformation if (req.operation === "DELETE") { + webhookTimer.stop(); return response; }