From 7a01eb42842d091924082c1861b06457b43bd249 Mon Sep 17 00:00:00 2001 From: annaweber Date: Sat, 21 Feb 2026 07:56:51 -0800 Subject: [PATCH 1/3] fix: init fix --- src/libs/SearchQueryUtils.ts | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/libs/SearchQueryUtils.ts b/src/libs/SearchQueryUtils.ts index 9e143fbef6aa..33871b119229 100644 --- a/src/libs/SearchQueryUtils.ts +++ b/src/libs/SearchQueryUtils.ts @@ -1551,6 +1551,14 @@ function getQueryWithUpdatedValues(query: string, shouldSkipAmountConversion = f const computeNodeValue = (left: ValueOf, right: string | string[]) => getUpdatedFilterValue(left, right, shouldSkipAmountConversion); const standardizedQuery = traverseAndUpdatedQuery(queryJSON, computeNodeValue); + const normalizedQuery = query.toLowerCase(); + const hasInFilter = normalizedQuery.includes(`${CONST.SEARCH.SYNTAX_FILTER_KEYS.IN.toLowerCase()}:`); + const hasExplicitType = normalizedQuery.includes(`${CONST.SEARCH.SYNTAX_ROOT_KEYS.TYPE.toLowerCase()}:`); + + if (hasInFilter && !hasExplicitType) { + standardizedQuery.type = CONST.SEARCH.DATA_TYPES.CHAT; + } + return buildSearchQueryString(standardizedQuery); } From e9bd00738389153f9a06a4e8b69032b93a01d873 Mon Sep 17 00:00:00 2001 From: annaweber Date: Mon, 9 Mar 2026 15:19:39 -0700 Subject: [PATCH 2/3] fix: getRawFilterListFromQuery --- src/libs/SearchQueryUtils.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/libs/SearchQueryUtils.ts b/src/libs/SearchQueryUtils.ts index 33871b119229..44708dbe5083 100644 --- a/src/libs/SearchQueryUtils.ts +++ b/src/libs/SearchQueryUtils.ts @@ -1551,9 +1551,9 @@ function getQueryWithUpdatedValues(query: string, shouldSkipAmountConversion = f const computeNodeValue = (left: ValueOf, right: string | string[]) => getUpdatedFilterValue(left, right, shouldSkipAmountConversion); const standardizedQuery = traverseAndUpdatedQuery(queryJSON, computeNodeValue); - const normalizedQuery = query.toLowerCase(); - const hasInFilter = normalizedQuery.includes(`${CONST.SEARCH.SYNTAX_FILTER_KEYS.IN.toLowerCase()}:`); - const hasExplicitType = normalizedQuery.includes(`${CONST.SEARCH.SYNTAX_ROOT_KEYS.TYPE.toLowerCase()}:`); + const rawFilterList = getRawFilterListFromQuery(query); + const hasInFilter = rawFilterList?.some((filter) => !filter.isDefault && filter.key === CONST.SEARCH.SYNTAX_FILTER_KEYS.IN) ?? false; + const hasExplicitType = rawFilterList?.some((filter) => !filter.isDefault && filter.key === CONST.SEARCH.SYNTAX_ROOT_KEYS.TYPE) ?? false; if (hasInFilter && !hasExplicitType) { standardizedQuery.type = CONST.SEARCH.DATA_TYPES.CHAT; From afda1428fe57453dbd04bfc5fd925f00df39d36d Mon Sep 17 00:00:00 2001 From: annaweber Date: Sun, 12 Apr 2026 23:59:06 -0700 Subject: [PATCH 3/3] fix: task search --- src/libs/SearchQueryUtils.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/libs/SearchQueryUtils.ts b/src/libs/SearchQueryUtils.ts index 0814c28d4845..a84f515bb71b 100644 --- a/src/libs/SearchQueryUtils.ts +++ b/src/libs/SearchQueryUtils.ts @@ -1579,7 +1579,7 @@ function getQueryWithUpdatedValues(query: string, shouldSkipAmountConversion = f const standardizedQuery = traverseAndUpdatedQuery(queryJSON, computeNodeValue); const rawFilterList = getRawFilterListFromQuery(query); const hasInFilter = rawFilterList?.some((filter) => !filter.isDefault && filter.key === CONST.SEARCH.SYNTAX_FILTER_KEYS.IN) ?? false; - const hasExplicitType = rawFilterList?.some((filter) => !filter.isDefault && filter.key === CONST.SEARCH.SYNTAX_ROOT_KEYS.TYPE) ?? false; + const hasExplicitType = rawFilterList?.some((filter) => filter.key === CONST.SEARCH.SYNTAX_ROOT_KEYS.TYPE) ?? false; if (hasInFilter && !hasExplicitType) { standardizedQuery.type = CONST.SEARCH.DATA_TYPES.CHAT;