From 2dce264aff0945a7d2dabc3454134f90d03fa0c9 Mon Sep 17 00:00:00 2001 From: Flouse <1297478+Flouse@users.noreply.github.com> Date: Thu, 11 Jan 2024 02:39:14 +0000 Subject: [PATCH] chore(fmt): cargo +nightly fmt --all --- core/cli/src/args/generate_keypair.rs | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/core/cli/src/args/generate_keypair.rs b/core/cli/src/args/generate_keypair.rs index 12b009c2e..09cd71ec2 100644 --- a/core/cli/src/args/generate_keypair.rs +++ b/core/cli/src/args/generate_keypair.rs @@ -21,7 +21,7 @@ pub struct GenerateKeypairArgs { help = "The number of keypairs to generate.", default_value = "1" )] - pub num: usize, + pub num: usize, #[arg( short = 'p', long = "path", @@ -60,13 +60,13 @@ impl GenerateKeypairArgs { #[derive(Serialize, Clone, Debug)] pub struct Keypair { - pub index: usize, + pub index: usize, pub net_private_key: Hex, - pub public_key: Hex, - pub address: Address, - pub peer_id: String, + pub public_key: Hex, + pub address: Address, + pub peer_id: String, pub bls_private_key: Hex, - pub bls_public_key: Hex, + pub bls_public_key: Hex, } impl Keypair { @@ -90,13 +90,13 @@ impl Keypair { let bls_pub_key = bls_priv_key.pub_key(&String::new()); Ok(Keypair { - index: i, + index: i, net_private_key: Hex::encode(&net_seckey), - public_key: Hex::encode(&pubkey), - address: Address::from_pubkey_bytes(pubkey).map_err(Error::Running)?, - peer_id: secio_keypair.public_key().peer_id().to_base58(), + public_key: Hex::encode(&pubkey), + address: Address::from_pubkey_bytes(pubkey).map_err(Error::Running)?, + peer_id: secio_keypair.public_key().peer_id().to_base58(), bls_private_key: Hex::encode(&bls_seckey), - bls_public_key: Hex::encode(bls_pub_key.to_bytes()), + bls_public_key: Hex::encode(bls_pub_key.to_bytes()), }) }