From 0a62fd5f0e89ce63d47de830e0e101f98381a378 Mon Sep 17 00:00:00 2001 From: ryardley Date: Sun, 3 Nov 2024 15:35:03 +0700 Subject: [PATCH] Format code --- packages/ciphernode/core/src/lib.rs | 1 - packages/ciphernode/evm/src/ciphernode_registry_sol.rs | 5 ++++- packages/ciphernode/evm/src/helpers.rs | 8 ++------ packages/ciphernode/evm/src/registry_filter_sol.rs | 3 ++- 4 files changed, 8 insertions(+), 9 deletions(-) diff --git a/packages/ciphernode/core/src/lib.rs b/packages/ciphernode/core/src/lib.rs index 8100472a..154d1461 100644 --- a/packages/ciphernode/core/src/lib.rs +++ b/packages/ciphernode/core/src/lib.rs @@ -9,4 +9,3 @@ mod ordered_set; pub use eventbus::*; pub use events::*; pub use ordered_set::*; - diff --git a/packages/ciphernode/evm/src/ciphernode_registry_sol.rs b/packages/ciphernode/evm/src/ciphernode_registry_sol.rs index 3eda93f2..49193e41 100644 --- a/packages/ciphernode/evm/src/ciphernode_registry_sol.rs +++ b/packages/ciphernode/evm/src/ciphernode_registry_sol.rs @@ -1,4 +1,7 @@ -use crate::{helpers::{ReadonlyProvider, WithChainId}, EvmEventReader}; +use crate::{ + helpers::{ReadonlyProvider, WithChainId}, + EvmEventReader, +}; use actix::Addr; use alloy::{ primitives::{LogData, B256}, diff --git a/packages/ciphernode/evm/src/helpers.rs b/packages/ciphernode/evm/src/helpers.rs index 7c1ae78c..ecaf7f73 100644 --- a/packages/ciphernode/evm/src/helpers.rs +++ b/packages/ciphernode/evm/src/helpers.rs @@ -31,11 +31,7 @@ pub async fn stream_from_evm, T: Transport + Clone>( extractor: fn(&LogData, Option<&B256>, u64) -> Option, mut shutdown: oneshot::Receiver<()>, ) { - match provider - .get_provider() - .subscribe_logs(&filter) - .await - { + match provider.get_provider().subscribe_logs(&filter).await { Ok(subscription) => { let mut stream = subscription.into_stream(); loop { @@ -63,7 +59,7 @@ pub async fn stream_from_evm, T: Transport + Clone>( } } Err(e) => { - bus.err(EnclaveErrorType::Evm, anyhow!("{}",e)); + bus.err(EnclaveErrorType::Evm, anyhow!("{}", e)); } }; info!("Exiting stream loop"); diff --git a/packages/ciphernode/evm/src/registry_filter_sol.rs b/packages/ciphernode/evm/src/registry_filter_sol.rs index 65f70a55..2c8dedf9 100644 --- a/packages/ciphernode/evm/src/registry_filter_sol.rs +++ b/packages/ciphernode/evm/src/registry_filter_sol.rs @@ -3,7 +3,8 @@ use actix::prelude::*; use alloy::{ primitives::{Address, Bytes, U256}, rpc::types::TransactionReceipt, - sol, transports::BoxTransport, + sol, + transports::BoxTransport, }; use anyhow::Result; use enclave_core::{