mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-09-27 23:46:17 +02:00
input+sweep: let weightestimator take known TxOut
This commit is contained in:
@@ -533,6 +533,14 @@ func (twe *TxWeightEstimator) AddNestedP2WSHInput(witnessSize int) *TxWeightEsti
|
||||
return twe
|
||||
}
|
||||
|
||||
// AddTxOutput adds a known TxOut to the weight estimator.
|
||||
func (twe *TxWeightEstimator) AddTxOutput(txOut *wire.TxOut) *TxWeightEstimator {
|
||||
twe.outputSize += txOut.SerializeSize()
|
||||
twe.outputCount++
|
||||
|
||||
return twe
|
||||
}
|
||||
|
||||
// AddP2PKHOutput updates the weight estimate to account for an additional P2PKH
|
||||
// output.
|
||||
func (twe *TxWeightEstimator) AddP2PKHOutput() *TxWeightEstimator {
|
||||
|
Reference in New Issue
Block a user