mirror of
https://github.com/bisq-network/bisq.git
synced 2025-02-23 15:00:30 +01:00
When creating a BSQ transaction (actually at commit time as we can create a tx and then cancel it in the confirmation popup) we store the change output (only that not the other possible BSQ output) in a persisted list. The BsqCoinSelector will take that list to allow spending those coins. We use the txType to find the index of the cahnge output. We only have one change output in the transactions created in Bisq. Multiple change outputs would be valid but our goal is only increased usability in the Bisq app and it is not related to validation rules. We update out list at each new block confirmation. With that approach we avoid too much dependencies to the BitcoinJ side. - Add UnconfirmedBsqChangeOutputListService and persisted UnconfirmedBsqChangeOutputList for storing unconfirmed outputs - Add lookup for unconfirmed BSQ change outputs at BsqCoinSelector and allow spending if found - Pass TxType for walletsManager.publishAndCommitBsqTx calls - Add TxType to bsqWalletService.commitTx - Refactor getPreparedSendTx methods for BSQ and BTC sending to one common method with a coinselector parameter. - Add getChangeAddress method to BsqWalletService to make change outputs more explicit - Add unconfirmedChangeBalance to onUpdateBalances handlers - Rename availableBalance to availableConfirmedBalance in onUpdateBalances - Unify onUpdateBalances parameter names |
||
---|---|---|
.. | ||
src |