diff --git a/backend/src/graphql/resolver/util/findContributions.ts b/backend/src/graphql/resolver/util/findContributions.ts index 762f9ace0..ab504b37c 100644 --- a/backend/src/graphql/resolver/util/findContributions.ts +++ b/backend/src/graphql/resolver/util/findContributions.ts @@ -33,7 +33,7 @@ export const findContributions = async ( ...(statusFilter?.length && { contributionStatus: In(statusFilter) }), ...(userId && { userId }), } - + let where = query && relations?.user ? [ @@ -59,13 +59,13 @@ export const findContributions = async ( }, { ...requiredWhere, - memo: Like(`%${query}%`) + memo: Like(`%${query}%`), }, ] : requiredWhere - + if (!relations?.user && query) { - where = [{...requiredWhere, memo: Like(`%${query}%`)}] + where = [{ ...requiredWhere, memo: Like(`%${query}%`) }] } return DbContribution.findAndCount({