diff --git a/src/wallet/tx_builder.rs b/src/wallet/tx_builder.rs index 089aad43..a9ed5d8b 100644 --- a/src/wallet/tx_builder.rs +++ b/src/wallet/tx_builder.rs @@ -414,6 +414,10 @@ impl<'a, B, D: BatchDatabase, Cs: CoinSelectionAlgorithm, Ctx: TxBuilderConte self, coin_selection: P, ) -> TxBuilder<'a, B, D, P, Ctx> { + assert!( + self.coin_selection.is_some(), + "can't set coin_selection after finish() has been called" + ); TxBuilder { wallet: self.wallet, params: self.params,