mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-07-04 04:21:12 +02:00
contractcourt: remove unused bucket justice-txn
We never writes data to this bucket so it's removed.
This commit is contained in:
@ -47,11 +47,6 @@ var (
|
|||||||
// procedure, we can recover and continue from the persisted state.
|
// procedure, we can recover and continue from the persisted state.
|
||||||
retributionBucket = []byte("retribution")
|
retributionBucket = []byte("retribution")
|
||||||
|
|
||||||
// justiceTxnBucket holds the finalized justice transactions for all
|
|
||||||
// breached contracts. Entries are added to the justice txn bucket just
|
|
||||||
// before broadcasting the sweep txn.
|
|
||||||
justiceTxnBucket = []byte("justice-txn")
|
|
||||||
|
|
||||||
// errBrarShuttingDown is an error returned if the breacharbiter has
|
// errBrarShuttingDown is an error returned if the breacharbiter has
|
||||||
// been signalled to exit.
|
// been signalled to exit.
|
||||||
errBrarShuttingDown = errors.New("breacharbiter shutting down")
|
errBrarShuttingDown = errors.New("breacharbiter shutting down")
|
||||||
@ -1578,18 +1573,7 @@ func (rs *RetributionStore) Remove(chanPoint *wire.OutPoint) error {
|
|||||||
|
|
||||||
// Remove the persisted retribution info and finalized justice
|
// Remove the persisted retribution info and finalized justice
|
||||||
// transaction.
|
// transaction.
|
||||||
if err := retBucket.Delete(chanBytes); err != nil {
|
return retBucket.Delete(chanBytes)
|
||||||
return err
|
|
||||||
}
|
|
||||||
|
|
||||||
// If we have not finalized this channel breach, we can exit
|
|
||||||
// early.
|
|
||||||
justiceBkt := tx.ReadWriteBucket(justiceTxnBucket)
|
|
||||||
if justiceBkt == nil {
|
|
||||||
return nil
|
|
||||||
}
|
|
||||||
|
|
||||||
return justiceBkt.Delete(chanBytes)
|
|
||||||
}, func() {})
|
}, func() {})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user