mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-04-08 20:28:04 +02:00
sweep: add new error ErrZeroFeeRateDelta
This commit is contained in:
parent
6c2e8b9a00
commit
5f64280df4
@ -14,6 +14,9 @@ var (
|
||||
// ErrMaxPosition is returned when trying to increase the position of
|
||||
// the fee function while it's already at its max.
|
||||
ErrMaxPosition = errors.New("position already at max")
|
||||
|
||||
// ErrZeroFeeRateDelta is returned when the fee rate delta is zero.
|
||||
ErrZeroFeeRateDelta = errors.New("fee rate delta is zero")
|
||||
)
|
||||
|
||||
// mSatPerKWeight represents a fee rate in msat/kw.
|
||||
@ -169,7 +172,7 @@ func NewLinearFeeFunction(maxFeeRate chainfee.SatPerKWeight,
|
||||
"endingFeeRate=%v, width=%v, delta=%v", start, end,
|
||||
l.width, l.deltaFeeRate)
|
||||
|
||||
return nil, fmt.Errorf("fee rate delta is zero")
|
||||
return nil, ErrZeroFeeRateDelta
|
||||
}
|
||||
|
||||
// Attach the calculated values to the fee function.
|
||||
|
Loading…
x
Reference in New Issue
Block a user