mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-04 20:37:15 +02:00
Everyone uses the SearchContext::word_docids instead of get_db_word_docids
make get_db_word_docids private
This commit is contained in:
parent
325f17488a
commit
5ab46324c4
7 changed files with 46 additions and 27 deletions
|
@ -9,7 +9,7 @@ use super::interner::Interned;
|
|||
use super::query_graph::QueryNodeData;
|
||||
use super::query_term::{Phrase, QueryTermSubset};
|
||||
use super::small_bitmap::SmallBitmap;
|
||||
use super::{QueryGraph, SearchContext};
|
||||
use super::{QueryGraph, SearchContext, Word};
|
||||
use crate::search::new::query_term::LocatedQueryTermSubset;
|
||||
use crate::Result;
|
||||
|
||||
|
@ -35,7 +35,7 @@ pub fn compute_query_term_subset_docids(
|
|||
) -> Result<RoaringBitmap> {
|
||||
let mut docids = RoaringBitmap::new();
|
||||
for word in term.all_single_words_except_prefix_db(ctx)? {
|
||||
if let Some(word_docids) = ctx.get_db_word_docids(word)? {
|
||||
if let Some(word_docids) = ctx.word_docids(word)? {
|
||||
docids |= word_docids;
|
||||
}
|
||||
}
|
||||
|
@ -125,7 +125,7 @@ pub fn compute_phrase_docids(
|
|||
}
|
||||
if words.len() == 1 {
|
||||
if let Some(word) = &words[0] {
|
||||
if let Some(word_docids) = ctx.get_db_word_docids(*word)? {
|
||||
if let Some(word_docids) = ctx.word_docids(Word::Original(*word))? {
|
||||
return Ok(word_docids);
|
||||
} else {
|
||||
return Ok(RoaringBitmap::new());
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue