mirror of
https://github.com/meilisearch/MeiliSearch
synced 2024-11-26 23:04:26 +01:00
Lowercase quoted words
This commit is contained in:
parent
883a8109c8
commit
1bd37d213a
@ -152,7 +152,7 @@ impl Index {
|
|||||||
let dfas = words.into_iter().enumerate().map(|(i, word)| {
|
let dfas = words.into_iter().enumerate().map(|(i, word)| {
|
||||||
let (word, quoted) = match word {
|
let (word, quoted) = match word {
|
||||||
QueryToken::Free(word) => (word.cow_to_lowercase(), word.len() <= 3),
|
QueryToken::Free(word) => (word.cow_to_lowercase(), word.len() <= 3),
|
||||||
QueryToken::Quoted(word) => (Cow::Borrowed(word), true),
|
QueryToken::Quoted(word) => (word.cow_to_lowercase(), true),
|
||||||
};
|
};
|
||||||
let is_last = i + 1 == number_of_words;
|
let is_last = i + 1 == number_of_words;
|
||||||
let is_prefix = is_last && !ends_with_whitespace && !quoted;
|
let is_prefix = is_last && !ends_with_whitespace && !quoted;
|
||||||
|
Loading…
Reference in New Issue
Block a user