From 221c4a7fb2b531f16adf5beb242bf29ca502e3f0 Mon Sep 17 00:00:00 2001 From: Astro Date: Tue, 1 Aug 2023 21:52:45 +0200 Subject: [PATCH] cave/feed: report url_host() errors --- cave/src/feed.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/cave/src/feed.rs b/cave/src/feed.rs index f383119..d0896f0 100644 --- a/cave/src/feed.rs +++ b/cave/src/feed.rs @@ -5,6 +5,7 @@ use eventsource_stream::Eventsource; pub fn url_host(url: &str) -> Option { reqwest::Url::parse(url) + .map_err(|e| tracing::warn!("Cannot parse url {:?}: {}", url, e)) .ok() .and_then(|url| url.domain() .map(|host| host.to_lowercase())