Removed unwrap and added ?

pull/370/head
BlackDex 6 years ago
parent da068a43c1
commit 4de16b2d17

@ -283,7 +283,7 @@ fn fix_href(href: &str, url: &str) -> String {
} }
fn download_icon(domain: &str) -> Result<Vec<u8>, Error> { fn download_icon(domain: &str) -> Result<Vec<u8>, Error> {
let url = get_icon_url(&domain).unwrap(); let url = get_icon_url(&domain)?;
info!("Downloading icon for {} via {}...",domain, url); info!("Downloading icon for {} via {}...",domain, url);
let mut res = reqwest::get(&url)?; let mut res = reqwest::get(&url)?;

Loading…
Cancel
Save