mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-18 10:31:15 +00:00
refactor(core): Switch plain errors in cli to ApplicationError (#7857)
Ensure all errors in `cli` are `ApplicationError` or children of it and contain no variables in the message, to continue normalizing all the errors we report to Sentry Follow-up to: https://github.com/n8n-io/n8n/pull/7839
This commit is contained in:
@@ -30,6 +30,7 @@ import {
|
||||
WorkflowActivationError,
|
||||
ErrorReporterProxy as ErrorReporter,
|
||||
WebhookPathTakenError,
|
||||
ApplicationError,
|
||||
} from 'n8n-workflow';
|
||||
|
||||
import type express from 'express';
|
||||
@@ -425,7 +426,7 @@ export class ActiveWorkflowRunner implements IWebhookManager {
|
||||
});
|
||||
|
||||
if (workflowData === null) {
|
||||
throw new Error(`Could not find workflow with id "${workflowId}"`);
|
||||
throw new ApplicationError('Could not find workflow', { extra: { workflowId } });
|
||||
}
|
||||
|
||||
const workflow = new Workflow({
|
||||
|
||||
Reference in New Issue
Block a user