storeRevertedTransaction method

Future<void> storeRevertedTransaction(
  1. String walletId,
  2. BitcoinTransaction transaction
)

Stores transaction as the row of (walletId, txid) with the status, block height and confirmations it carries, even when that lowers a confirmed status: the one way a confirmation is taken back, used for a reorganization past the confirming block or a proof its block header contradicts (audit 3b0, bead libspiffy-7dj). A non-confirmed record clears the stored block height. Raw hex and the other rules of storeTransaction apply; nothing is deleted.

The default implementation calls storeTransaction (for a backend without the status rule); the libspiffy backends override it.

Implementation

Future<void> storeRevertedTransaction(String walletId, BitcoinTransaction transaction) =>
    storeTransaction(walletId, transaction);