Skip to content

Commit

Permalink
fmnt and clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
SWvheerden committed Jul 2, 2024
1 parent a7d945a commit 85c7b50
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
1 change: 0 additions & 1 deletion base_layer/core/src/blocks/faucets/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,6 @@ mod test {
let mut utxo_file = File::create("utxos.json").expect("Could not create utxos.json");

for output in outputs {
dbg!(&output);
let utxo_s = serde_json::to_string(&output).unwrap();
utxo_file.write_all(format!("{}\n", utxo_s).as_bytes()).unwrap();
}
Expand Down
15 changes: 1 addition & 14 deletions base_layer/wallet/src/transaction_service/service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1434,9 +1434,7 @@ where
JoinHandle<Result<TxId, TransactionServiceProtocolError<TxId>>>,
>,
) -> Result<TxId, TransactionServiceError> {
println!("searching for tx");
let mut transaction = self.db.get_completed_transaction(tx_id)?;
println!("found tx");

transaction.transaction.script_offset = &transaction.transaction.script_offset + &script_offset;

Expand Down Expand Up @@ -1464,7 +1462,6 @@ where
),
)?;

println!("update meta signature");
transaction.transaction.body.update_script_signature(
&transaction.transaction.body.inputs()[0].commitment()?.clone(),
&ComAndPubSignature::new(
Expand All @@ -1483,32 +1480,24 @@ where
),
)?;

println!("update script signature");
let res = self
let _res = self
.resources
.output_manager_service
.update_output_metadata_signature(transaction.transaction.body.outputs()[0].clone())
.await;
dbg!(&res);
// res?;

println!("update oms db signature");
self.db.update_completed_transaction(tx_id, transaction)?;
println!("update db signature");

self.resources
.output_manager_service
.confirm_pending_transaction(tx_id)
.await?;

println!("confirm the tx");

// Notify that the transaction was successfully resolved.
let _size = self
.event_publisher
.send(Arc::new(TransactionEvent::TransactionCompletedImmediately(tx_id)));

println!("publish sent");
self.complete_send_transaction_protocol(
Ok(TransactionSendResult {
tx_id,
Expand All @@ -1517,8 +1506,6 @@ where
transaction_broadcast_join_handles,
);

println!("complete the tx");

Ok(tx_id)
}

Expand Down

0 comments on commit 85c7b50

Please sign in to comment.