Skip to content

Commit

Permalink
fix(backend): add missing filter
Browse files Browse the repository at this point in the history
  • Loading branch information
Mati365 committed Dec 15, 2024
1 parent 491661e commit 362fd6f
Showing 1 changed file with 2 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -56,12 +56,14 @@ export class ProjectsFilesEsSearchRepo {

private static createEsRequestSearchFilters = (
{
projectId,
phrase,
ids,
}: InternalSearchProjectFilesInput,
): esb.Query =>
esb.boolQuery().must(
rejectFalsyItems([
esb.termQuery('project.id', projectId),
!!ids?.length && esb.termsQuery('id', ids),
!!phrase && createPhraseFieldQuery()(phrase).boost(3),
]),
Expand Down

0 comments on commit 362fd6f

Please sign in to comment.