lnwallet: properly use in KB, not KiB to convert to sat/byte for bitcoind estimator
In this commit, we fix an existing bug. The fee estimation within bitcoind is based on fee/KB (1000), not fee/KiB (1024). Pointed out by @dabura667.
This commit is contained in:
parent
47dc2d3b70
commit
63fe8aec5b
@ -331,9 +331,9 @@ func (b *BitcoindFeeEstimator) fetchEstimatePerByte(confTarget uint32) (btcutil.
|
||||
}
|
||||
|
||||
// The value returned is expressed in fees per KB, while we want
|
||||
// fee-per-byte, so we'll divide by 1024 to map to satoshis-per-byte
|
||||
// fee-per-byte, so we'll divide by 1000 to map to satoshis-per-byte
|
||||
// before returning the estimate.
|
||||
satPerByte := satPerKB / 1024
|
||||
satPerByte := satPerKB / 1000
|
||||
|
||||
walletLog.Debugf("Returning %v sat/byte for conf target of %v",
|
||||
int64(satPerByte), confTarget)
|
||||
|
Loading…
Reference in New Issue
Block a user