Skip to content

Commit

Permalink
checkIsWorkflowPartOfProject: correct checking logic. We're looking a…
Browse files Browse the repository at this point in the history
…t WF ID, not Subject Sets.
  • Loading branch information
shaunanoordin committed Nov 4, 2024
1 parent 72dc2a3 commit 4bcf4e9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ Checks if a workflow belongs to a project.

export default function checkIsWorkflowPartOfProject(workflow, project) {
if (!workflow || !project) return false;
return !!workflow.links?.subject_sets?.some(sset => project.links?.subject_sets?.includes(sset));
return !!project.links?.workflows?.includes(workflow.id);
}

0 comments on commit 4bcf4e9

Please sign in to comment.