mirror of
https://github.com/meilisearch/meilisearch.git
synced 2024-11-30 09:04:59 +08:00
fix http-ui
This commit is contained in:
parent
7d36d664a7
commit
608c5bad24
@ -144,7 +144,7 @@ impl<'a, A: AsRef<[u8]>> Highlighter<'a, A> {
|
|||||||
let analyzed = self.analyzer.analyze(&old_string);
|
let analyzed = self.analyzer.analyze(&old_string);
|
||||||
for (word, token) in analyzed.reconstruct() {
|
for (word, token) in analyzed.reconstruct() {
|
||||||
if token.is_word() {
|
if token.is_word() {
|
||||||
let to_highlight = matching_words.matches(token.text());
|
let to_highlight = matching_words.matching_bytes(token.text()).is_some();
|
||||||
if to_highlight { string.push_str("<mark>") }
|
if to_highlight { string.push_str("<mark>") }
|
||||||
string.push_str(word);
|
string.push_str(word);
|
||||||
if to_highlight { string.push_str("</mark>") }
|
if to_highlight { string.push_str("</mark>") }
|
||||||
|
Loading…
Reference in New Issue
Block a user