web search done right
if there is no cleantext on site, then we probably can't create a good snippet anyway
Mikkel Denker00bc05cfba32
diff --git a/core/src/snippet.rs b/core/src/snippet.rsindex db2523a9..c14b8863 100644--- a/core/src/snippet.rs+++ b/core/src/snippet.rs@@ -231,6 +231,10 @@ pub fn generate(query: &Query, text: &str, region: &Region, config: SnippetConfiNone => whatlang::detect_lang(text).unwrap_or(Lang::Eng),};+ if text.is_empty() {+ return text.to_string();+ }+let snippet = snippet_string(text, query.simple_terms(), lang, config);snippet.to_html()