From 1520be463ba2de848a65054623d83aeca0c382be Mon Sep 17 00:00:00 2001 From: Harpreet Sangar Date: Mon, 8 May 2023 10:28:36 +0530 Subject: [PATCH] Fix failing join tests. --- src/index.cpp | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/index.cpp b/src/index.cpp index ddfd75f8..207c44bb 100644 --- a/src/index.cpp +++ b/src/index.cpp @@ -1362,6 +1362,7 @@ void Index::search_all_candidates(const size_t num_search_fields, id_buff, all_result_ids, all_result_ids_len); query_hashes.insert(qhash); + filter_result_iterator->reset(); } } @@ -2571,7 +2572,6 @@ Option Index::search(std::vector& field_query_tokens, cons typo_tokens_threshold, exhaustive_search, max_candidates, min_len_1typo, min_len_2typo, syn_orig_num_tokens, sort_order, field_values, geopoint_indices); - filter_result_iterator->reset(); // try split/joining tokens if no results are found if(split_join_tokens == always || (all_result_ids_len == 0 && split_join_tokens == fallback)) { @@ -2608,7 +2608,6 @@ Option Index::search(std::vector& field_query_tokens, cons all_result_ids, all_result_ids_len, group_limit, group_by_fields, prioritize_exact_match, prioritize_token_position, query_hashes, token_order, prefixes, typo_tokens_threshold, exhaustive_search, max_candidates, min_len_1typo, min_len_2typo, syn_orig_num_tokens, sort_order, field_values, geopoint_indices); - filter_result_iterator->reset(); } } @@ -2681,7 +2680,6 @@ Option Index::search(std::vector& field_query_tokens, cons token_order, prefixes, typo_tokens_threshold, exhaustive_search, max_candidates, min_len_1typo, min_len_2typo, -1, sort_order, field_values, geopoint_indices); - filter_result_iterator->reset(); } else { break;