Enable some more lints; fix clippy issues
This commit is contained in:
parent
b53365a293
commit
a67df934bf
|
@ -1,9 +1,11 @@
|
|||
#![doc = include_str!("../README.md")]
|
||||
#![warn(
|
||||
clippy::all,
|
||||
missing_copy_implementations,
|
||||
missing_debug_implementations,
|
||||
rust_2018_idioms,
|
||||
rustdoc::broken_intra_doc_links
|
||||
rustdoc::broken_intra_doc_links,
|
||||
trivial_numeric_casts
|
||||
)]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
|
|
|
@ -1,9 +1,11 @@
|
|||
#![doc = include_str!("../README.md")]
|
||||
#![warn(
|
||||
clippy::all,
|
||||
missing_copy_implementations,
|
||||
missing_debug_implementations,
|
||||
rust_2018_idioms,
|
||||
rustdoc::broken_intra_doc_links
|
||||
rustdoc::broken_intra_doc_links,
|
||||
trivial_numeric_casts
|
||||
)]
|
||||
#![deny(missing_docs)]
|
||||
|
||||
|
|
|
@ -147,10 +147,12 @@ pub(crate) async fn redirect_url(key: &str) -> Result<String> {
|
|||
let direct_url = String::from_utf8_lossy(&output.stdout)
|
||||
.trim_end()
|
||||
.to_owned();
|
||||
|
||||
if direct_url.is_empty() {
|
||||
return Err(Error::NoRedirectUrlFound);
|
||||
Err(Error::NoRedirectUrlFound)
|
||||
} else {
|
||||
println!(" Found direct URL: {direct_url}");
|
||||
|
||||
Ok(direct_url)
|
||||
}
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue