From 1dd35cfc9e7e34b2294da9123165e4523ced1a20 Mon Sep 17 00:00:00 2001 From: Marco Granelli Date: Tue, 12 Sep 2023 15:38:34 +0200 Subject: [PATCH] Clippy + fmt --- apps/src/lib/cli.rs | 1 - apps/src/lib/client/utils.rs | 3 +-- tests/src/e2e/setup.rs | 3 +-- 3 files changed, 2 insertions(+), 5 deletions(-) diff --git a/apps/src/lib/cli.rs b/apps/src/lib/cli.rs index f0b001beba..c4f22538ec 100644 --- a/apps/src/lib/cli.rs +++ b/apps/src/lib/cli.rs @@ -2455,7 +2455,6 @@ pub mod args { use std::collections::HashMap; use std::convert::TryFrom; use std::env; - use std::net::SocketAddr; use std::path::PathBuf; use std::str::FromStr; diff --git a/apps/src/lib/client/utils.rs b/apps/src/lib/client/utils.rs index 5e5bebc393..0c0d24772e 100644 --- a/apps/src/lib/client/utils.rs +++ b/apps/src/lib/client/utils.rs @@ -2,7 +2,6 @@ use std::collections::HashMap; use std::env; use std::fs::{self, File, OpenOptions}; use std::io::Write; -use std::net::SocketAddr; use std::path::{Path, PathBuf}; use std::str::FromStr; @@ -1050,7 +1049,7 @@ pub fn init_genesis_validator( tendermint_node_key: Some(HexString( pre_genesis.tendermint_node_key.ref_to().to_string(), )), - net_address: Some(net_address.to_string()), + net_address: Some(net_address), ..Default::default() }, )]), diff --git a/tests/src/e2e/setup.rs b/tests/src/e2e/setup.rs index c995547fbf..9a58230072 100644 --- a/tests/src/e2e/setup.rs +++ b/tests/src/e2e/setup.rs @@ -2,7 +2,6 @@ use std::collections::HashMap; use std::ffi::OsStr; use std::fmt::Display; use std::fs::{File, OpenOptions}; -use std::net::SocketAddr; use std::path::{Path, PathBuf}; use std::process::Command; use std::str::FromStr; @@ -124,7 +123,7 @@ where let other_validators = validator_0.clone(); let validator_0_target = validator_0.net_address.clone().unwrap(); let split: Vec<&str> = validator_0_target.split(':').collect(); - let (mut net_target_0, net_address_port_0) = + let (net_target_0, net_address_port_0) = (split[0], split[1].parse::().unwrap()); for ix in 0..num { let mut validator = other_validators.clone();