From 38826af279fb400f66f5cc16adaa3443190a166d Mon Sep 17 00:00:00 2001 From: hi-rustin Date: Thu, 16 Dec 2021 22:31:03 +0800 Subject: [PATCH] Make clippy happy Signed-off-by: hi-rustin --- src/bin/cargo/commands/help.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/bin/cargo/commands/help.rs b/src/bin/cargo/commands/help.rs index caaa0c5a496..16b7e71e6be 100644 --- a/src/bin/cargo/commands/help.rs +++ b/src/bin/cargo/commands/help.rs @@ -69,20 +69,20 @@ fn try_help(config: &Config) -> CargoResult { }; if resolve_executable(Path::new("man")).is_ok() { - let man = match extract_man(&subcommand, "1") { + let man = match extract_man(subcommand, "1") { Some(man) => man, None => return Ok(false), }; - write_and_spawn(&subcommand, &man, "man")?; + write_and_spawn(subcommand, &man, "man")?; } else { - let txt = match extract_man(&subcommand, "txt") { + let txt = match extract_man(subcommand, "txt") { Some(txt) => txt, None => return Ok(false), }; if resolve_executable(Path::new("less")).is_ok() { - write_and_spawn(&subcommand, &txt, "less")?; + write_and_spawn(subcommand, &txt, "less")?; } else if resolve_executable(Path::new("more")).is_ok() { - write_and_spawn(&subcommand, &txt, "more")?; + write_and_spawn(subcommand, &txt, "more")?; } else { drop(std::io::stdout().write_all(&txt)); }