mirror of
https://github.com/meilisearch/meilisearch.git
synced 2024-11-27 04:25:06 +08:00
Use the words criterion in the search module
This commit is contained in:
parent
3d731cc861
commit
22b84fe543
@ -66,12 +66,12 @@ impl<'a> Search<'a> {
|
||||
let before = Instant::now();
|
||||
let query_tree = match self.query.as_ref() {
|
||||
Some(query) => {
|
||||
let mut builder = QueryTreeBuilder::new(self.rtxn, self.index);
|
||||
let builder = QueryTreeBuilder::new(self.rtxn, self.index);
|
||||
let stop_words = &Set::default();
|
||||
let analyzer = Analyzer::new(AnalyzerConfig::default_with_stopwords(stop_words));
|
||||
let result = analyzer.analyze(query);
|
||||
let tokens = result.tokens();
|
||||
builder.build(tokens)
|
||||
builder.build(tokens)?
|
||||
},
|
||||
None => None,
|
||||
};
|
||||
|
Loading…
Reference in New Issue
Block a user