From ab126b9d7031cb193a0e5ecd2212182c69ebc603 Mon Sep 17 00:00:00 2001 From: Jann Marc Villablanca <31008330+jfvillablanca@users.noreply.github.com> Date: Sat, 14 Dec 2024 04:40:16 +0800 Subject: [PATCH] :alien: fix: `mojeek` parser update due to upstream breaking api changes (#640) --- src/engines/mojeek.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/engines/mojeek.rs b/src/engines/mojeek.rs index d3b13b6..60422d0 100644 --- a/src/engines/mojeek.rs +++ b/src/engines/mojeek.rs @@ -30,8 +30,8 @@ impl Mojeek { parser: SearchResultParser::new( ".result-col", ".results-standard li", - "a span.url", - "h2 a.title", + "h2 > a.title", + "a.ob", "p.s", )?, }) @@ -157,7 +157,7 @@ impl SearchEngine for Mojeek { .parse_for_results(&document, |title, url, desc| { Some(SearchResult::new( title.inner_html().trim(), - url.inner_html().trim(), + url.attr("href")?.trim(), desc.inner_html().trim(), &["mojeek"], ))