mirror of
https://github.com/RoboSats/taptrade-core.git
synced 2025-08-01 07:31:41 +00:00
maker fiat confirmation
This commit is contained in:
@ -28,7 +28,11 @@ pub fn run_maker(maker_config: &TraderSettings) -> Result<()> {
|
|||||||
|
|
||||||
let offer = ActiveOffer::create(&wallet, maker_config)?;
|
let offer = ActiveOffer::create(&wallet, maker_config)?;
|
||||||
dbg!(&offer);
|
dbg!(&offer);
|
||||||
let trade_psbt = offer.wait_until_taken(maker_config)?;
|
let mut escrow_contract_psbt = offer.wait_until_taken(maker_config)?;
|
||||||
|
|
||||||
|
wallet
|
||||||
|
.validate_maker_psbt(&escrow_contract_psbt)?
|
||||||
|
.sign_escrow_psbt(&mut escrow_contract_psbt)?;
|
||||||
|
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
@ -77,7 +77,7 @@ impl TradingWallet {
|
|||||||
// input amount should be the bond amount when buying,
|
// input amount should be the bond amount when buying,
|
||||||
pub fn validate_taker_psbt(&self, psbt: &PartiallySignedTransaction) -> Result<&Self> {
|
pub fn validate_taker_psbt(&self, psbt: &PartiallySignedTransaction) -> Result<&Self> {
|
||||||
dbg!("IMPLEMENT TAKER PSBT VALIDATION!");
|
dbg!("IMPLEMENT TAKER PSBT VALIDATION!");
|
||||||
// tbd once the trade psbt is implemented
|
// tbd once the trade psbt is implemented on coordinator side
|
||||||
Ok(self)
|
Ok(self)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -88,4 +88,10 @@ impl TradingWallet {
|
|||||||
}
|
}
|
||||||
Ok(self)
|
Ok(self)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
pub fn validate_maker_psbt(&self, psbt: &PartiallySignedTransaction) -> Result<&Self> {
|
||||||
|
dbg!("IMPLEMENT MAKER PSBT VALIDATION!");
|
||||||
|
// tbd once the trade psbt is implemented on coordinator side
|
||||||
|
Ok(self)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user