Skip to content

Commit

Permalink
chore: format files
Browse files Browse the repository at this point in the history
  • Loading branch information
NonsoAmadi10 authored and lorbax committed Jul 12, 2024
1 parent 2b06b18 commit 81942c9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
2 changes: 1 addition & 1 deletion roles/jd-server/src/lib/job_declarator/message_handler.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ use crate::mempool::JDsMempool;
use super::{signed_token, TransactionState};
use roles_logic_sv2::{errors::Error, parsers::PoolMessages as AllMessages};
use stratum_common::bitcoin::consensus::Decodable;
use tracing::{info, debug};
use tracing::{debug, info};

use super::JobDeclaratorDownstream;

Expand Down
5 changes: 2 additions & 3 deletions roles/jd-server/src/lib/mempool/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -95,13 +95,12 @@ impl JDsMempool {
}

pub async fn update_mempool(self_: Arc<Mutex<Self>>) -> Result<(), JdsMempoolError> {

let mut new_jds_mempool: HashMap<Txid, Option<Transaction>> = self_.safe_lock(|x| x.mempool.clone())?;
let mut new_jds_mempool: HashMap<Txid, Option<Transaction>> =
self_.safe_lock(|x| x.mempool.clone())?;
// the fat transactions in the jds-mempool are those declared by some downstream and we
// don't want to remove them, but we can get rid of the others
new_jds_mempool.retain(|_, val| val.is_some());


let client = self_
.safe_lock(|x| x.get_client())?
.ok_or(JdsMempoolError::NoClient)?;
Expand Down

0 comments on commit 81942c9

Please sign in to comment.