Resolve nightly-2021-10-05 clippy complaints
This commit is contained in:
@ -149,7 +149,7 @@ fn parse_settings(matches: &ArgMatches<'_>) -> Result<bool, Box<dyn error::Error
|
||||
|
||||
pub fn parse_args<'a>(
|
||||
matches: &ArgMatches<'_>,
|
||||
mut wallet_manager: &mut Option<Arc<RemoteWalletManager>>,
|
||||
wallet_manager: &mut Option<Arc<RemoteWalletManager>>,
|
||||
) -> Result<(CliConfig<'a>, CliSigners), Box<dyn error::Error>> {
|
||||
let config = if let Some(config_file) = matches.value_of("config_file") {
|
||||
Config::load(config_file).unwrap_or_default()
|
||||
@ -186,11 +186,11 @@ pub fn parse_args<'a>(
|
||||
let CliCommandInfo {
|
||||
command,
|
||||
mut signers,
|
||||
} = parse_command(matches, &default_signer, &mut wallet_manager)?;
|
||||
} = parse_command(matches, &default_signer, wallet_manager)?;
|
||||
|
||||
if signers.is_empty() {
|
||||
if let Ok(signer_info) =
|
||||
default_signer.generate_unique_signers(vec![None], matches, &mut wallet_manager)
|
||||
default_signer.generate_unique_signers(vec![None], matches, wallet_manager)
|
||||
{
|
||||
signers.extend(signer_info.signers);
|
||||
}
|
||||
|
@ -510,6 +510,7 @@ pub fn process_get_nonce(
|
||||
config: &CliConfig,
|
||||
nonce_account_pubkey: &Pubkey,
|
||||
) -> ProcessResult {
|
||||
#[allow(clippy::redundant_closure)]
|
||||
match get_account_with_commitment(rpc_client, nonce_account_pubkey, config.commitment)
|
||||
.and_then(|ref a| state_from_account(a))?
|
||||
{
|
||||
|
@ -215,6 +215,7 @@ fn full_battery_tests(
|
||||
}
|
||||
|
||||
#[test]
|
||||
#[allow(clippy::redundant_closure)]
|
||||
fn test_create_account_with_seed() {
|
||||
solana_logger::setup();
|
||||
let mint_keypair = Keypair::new();
|
||||
|
@ -1,3 +1,4 @@
|
||||
#![allow(clippy::redundant_closure)]
|
||||
use solana_cli::{
|
||||
cli::{process_command, request_and_confirm_airdrop, CliCommand, CliConfig},
|
||||
spend_utils::SpendAmount,
|
||||
|
@ -1,3 +1,4 @@
|
||||
#![allow(clippy::redundant_closure)]
|
||||
use solana_cli::{
|
||||
cli::{process_command, request_and_confirm_airdrop, CliCommand, CliConfig},
|
||||
spend_utils::SpendAmount,
|
||||
|
Reference in New Issue
Block a user