rustfmt staking-miner and fix typos

Signed-off-by: Uncle Stretch <uncle.stretch@ghostchain.io>
This commit is contained in:
Uncle Stretch
2025-07-29 14:38:49 +03:00
parent e21ac88235
commit ce26787a11
14 changed files with 1317 additions and 130 deletions

View File

@@ -6,7 +6,7 @@ use subxt::backend::rpc::RpcClient as RawRpcClient;
#[derive(Clone, Debug)]
pub struct Client {
/// Access to typed rpc calls from subxt.
rpc:: RpcClient,
rpc: RpcClient,
/// Access to chain APIs such as storage, events etc.
chain_api: ChainClient,
}
@@ -30,13 +30,16 @@ impl Client {
"failed to connect to client due to {:?}, retrying soon...",
e
);
},
}
};
tokio::time::sleep(std::time::Duration::from_millis(2_500)).await;
};
let chain_api = ChainClient::from_rpc_client(rpc.clone()).await?;
Ok(Self { rpc: RpcClient::new(rpc), chain_api })
Ok(Self {
rpc: RpcClient::new(rpc),
chain_api,
})
}
/// Get a reference to the RPC interface exposed by subxt.