diff --git a/src/services/imgur.rs b/src/services/imgur.rs index b6701b3..d6ebe33 100644 --- a/src/services/imgur.rs +++ b/src/services/imgur.rs @@ -115,7 +115,10 @@ impl Imgur { Ok(val["data"]["link"] .as_str() - .expect("imgur returned no image url!") + .unwrap_or_else(|| { + eprintln!("imgur returned no image url!\n{}", val); + std::process::exit(1) + }) .to_string()) } }