chore(core): Stop reporting RLC workflow ID error (#16659)

This commit is contained in:
Iván Ovejero
2025-06-24 12:14:14 +02:00
committed by GitHub
parent a6d0d9a5c9
commit 46258ed167

View File

@@ -1,6 +1,6 @@
import { WorkflowRepository } from '@n8n/db';
import { Service } from '@n8n/di';
import { UnexpectedError, type IWorkflowBase, type IWorkflowLoader } from 'n8n-workflow';
import { UserError, type IWorkflowBase, type IWorkflowLoader } from 'n8n-workflow';
@Service()
export class WorkflowLoaderService implements IWorkflowLoader {
@@ -10,7 +10,7 @@ export class WorkflowLoaderService implements IWorkflowLoader {
const workflow = await this.workflowRepository.findById(workflowId);
if (!workflow) {
throw new UnexpectedError(`Failed to find workflow with ID "${workflowId}"`);
throw new UserError(`Failed to find workflow with ID "${workflowId}"`);
}
return workflow;