fix: clone base db queries

This commit is contained in:
Ali BARIN
2023-08-03 19:07:01 +00:00
parent e4e3356dc9
commit 7ca37c412e
11 changed files with 13 additions and 0 deletions

View File

@@ -12,6 +12,7 @@ const getFlow = async (_parent: unknown, params: Params, context: Context) => {
const baseQuery = conditions.isCreator ? userFlows : allFlows;
const flow = await baseQuery
.clone()
.withGraphJoined('[steps.[connection]]')
.orderBy('steps.position', 'asc')
.findOne({ 'flows.id': params.id })