feat: v1.1.2 make clippy happy

This commit is contained in:
2022-04-03 17:03:31 +08:00
parent 97a29546bd
commit c8dc5703ab
8 changed files with 66 additions and 10 deletions

View File

@@ -23,7 +23,7 @@ impl Command for CommandImpl {
let json_output = sub_arg_matches.is_present("json");
if json_output { rust_util::util_msg::set_logger_std_out(false); }
let pin_opt = sub_arg_matches.value_of("pass").or(sub_arg_matches.value_of("pin"));
let pin_opt = sub_arg_matches.value_of("pass").or_else(|| sub_arg_matches.value_of("pin"));
let pin = opt_value_result!(pin_opt, "User pin must be assigned");
if pin.len() < 6 { return simple_error!("User pin length:{}, must >= 6!", pin.len()); }