mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-10-09 22:13:39 +02:00
sweep: leave exclusive group unchanged on parameter update
Exclusive group is a static property that doesn't need to be updated. Requiring the exclusive group to be passed into UpdateParams creates a burden for the caller to make sure they supply the existing group. This change will be beneficial for users that bump anchor sweeps that have exclusive groups set.
This commit is contained in:
@@ -1179,7 +1179,7 @@ func TestBumpFeeRBF(t *testing.T) {
|
||||
// We'll first try to bump the fee of an output currently unknown to the
|
||||
// UtxoSweeper. Doing so should result in a lnwallet.ErrNotMine error.
|
||||
_, err := ctx.sweeper.UpdateParams(
|
||||
wire.OutPoint{}, Params{Fee: lowFeePref},
|
||||
wire.OutPoint{}, ParamsUpdate{Fee: lowFeePref},
|
||||
)
|
||||
if err != lnwallet.ErrNotMine {
|
||||
t.Fatalf("expected error lnwallet.ErrNotMine, got \"%v\"", err)
|
||||
@@ -1208,13 +1208,13 @@ func TestBumpFeeRBF(t *testing.T) {
|
||||
ctx.estimator.blocksToFee[highFeePref.ConfTarget] = highFeeRate
|
||||
|
||||
// We should expect to see an error if a fee preference isn't provided.
|
||||
_, err = ctx.sweeper.UpdateParams(*input.OutPoint(), Params{})
|
||||
_, err = ctx.sweeper.UpdateParams(*input.OutPoint(), ParamsUpdate{})
|
||||
if err != ErrNoFeePreference {
|
||||
t.Fatalf("expected ErrNoFeePreference, got %v", err)
|
||||
}
|
||||
|
||||
bumpResult, err := ctx.sweeper.UpdateParams(
|
||||
*input.OutPoint(), Params{Fee: highFeePref},
|
||||
*input.OutPoint(), ParamsUpdate{Fee: highFeePref},
|
||||
)
|
||||
if err != nil {
|
||||
t.Fatalf("unable to bump input's fee: %v", err)
|
||||
|
Reference in New Issue
Block a user