fix: avoid panic when encountering malformed URLs

This commit is contained in:
FlashOnFire_ 2025-06-12 22:35:50 +02:00
parent f513cc541d
commit f7d5ec7a5a
No known key found for this signature in database
GPG key ID: BD1CF6A9A7126736

View file

@ -192,7 +192,10 @@ impl Scraper {
let next_full_url = match url.join(url_to_parse.as_str()) {
Ok(url) => url,
Err(e) => panic!("Failed to parse url: {} | Error: {}", next_url, e),
Err(e) => {
warn!("Failed to parse url: {} | Error: {}", next_url, e);
return;
},
};
let path = url_helper::to_path(&next_full_url, true);