sweep: rename NotifyPublishTx to StoreTx

To properly reflect what the method really does. We also changes the
method signature so only a hash is used.
This commit is contained in:
yyforyongyu committed 2024-04-19 21:33:19 +08:00
1 parent d4c1937572
commit e86843da6e
4 files changed
+12 -16

No files matched your search

+2 -2
View File
@@ -1176,9 +1176,9 @@ func (s *UtxoSweeper) sweep(inputs inputSet, feeRate chainfee.SatPerKWeight,
// publish, we loose track of this tx. Even republication on startup
// doesn't prevent this, because that call returns a double spend error
// then and would also not add the hash to the store.
err = s.cfg.Store.NotifyPublishTx(tx)
err = s.cfg.Store.StoreTx(tx.TxHash())
if err != nil {
return fmt.Errorf("notify publish tx: %w", err)
return fmt.Errorf("store tx: %w", err)
}
// Reschedule the inputs that we just tried to sweep. This is done in