Add mark_output_mined to SpWallet
This commit is contained in:
parent
6e3a13554c
commit
5b454c8158
@ -68,6 +68,12 @@ impl SpWallet {
|
|||||||
self.last_scan = last_scan;
|
self.last_scan = last_scan;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn mark_output_mined(&mut self, outpoint: &OutPoint, blk_hash: [u8; 32]) {
|
||||||
|
if let Some(output) = self.outputs.get_mut(outpoint) {
|
||||||
|
output.spend_status = OutputSpendStatus::Spent(blk_hash);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
pub fn update_with_transaction(&mut self, tx: &Transaction, public_tweak: &PublicKey, height: u32) -> Result<HashMap<OutPoint, OwnedOutput>> {
|
pub fn update_with_transaction(&mut self, tx: &Transaction, public_tweak: &PublicKey, height: u32) -> Result<HashMap<OutPoint, OwnedOutput>> {
|
||||||
let receiver = &self.get_sp_client().sp_receiver;
|
let receiver = &self.get_sp_client().sp_receiver;
|
||||||
let p2tr_outs: Vec<(usize, &TxOut)> = tx
|
let p2tr_outs: Vec<(usize, &TxOut)> = tx
|
||||||
|
Loading…
x
Reference in New Issue
Block a user