mirror of
https://github.com/Abdulazizzn/n8n-enterprise-unlocked.git
synced 2025-12-17 01:56:46 +00:00
fix: Restore missing tags in workflow retrieve (#5004)
This commit is contained in:
@@ -87,10 +87,12 @@ EEWorkflowController.get(
|
||||
ResponseHelper.send(async (req: WorkflowRequest.Get) => {
|
||||
const { id: workflowId } = req.params;
|
||||
|
||||
const workflow = await EEWorkflows.get(
|
||||
{ id: parseInt(workflowId, 10) },
|
||||
{ relations: ['shared', 'shared.user', 'shared.role'] },
|
||||
);
|
||||
const relations = ['shared', 'shared.user', 'shared.role'];
|
||||
if (!config.getEnv('workflowTagsDisabled')) {
|
||||
relations.push('tags');
|
||||
}
|
||||
|
||||
const workflow = await EEWorkflows.get({ id: parseInt(workflowId, 10) }, { relations });
|
||||
|
||||
if (!workflow) {
|
||||
throw new ResponseHelper.NotFoundError(`Workflow with ID "${workflowId}" does not exist`);
|
||||
|
||||
Reference in New Issue
Block a user