Skip to content

Commit dcd8e16

Browse files
authored
Merge pull request #8685 from ziggie1984/fix-bumpfee-immediate
fix lncli bumpfee flag parsing
2 parents 7f5f806 + 0ea45ef commit dcd8e16

File tree

2 files changed

+18
-1
lines changed

2 files changed

+18
-1
lines changed

cmd/lncli/walletrpc_active.go

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -272,10 +272,24 @@ func bumpFee(ctx *cli.Context) error {
272272
client, cleanUp := getWalletClient(ctx)
273273
defer cleanUp()
274274

275+
// Parse immediate flag (force flag was deprecated).
276+
immediate := false
277+
switch {
278+
case ctx.IsSet("immediate") && ctx.IsSet("force"):
279+
return fmt.Errorf("cannot set immediate and force flag at " +
280+
"the same time")
281+
282+
case ctx.Bool("immediate"):
283+
immediate = true
284+
285+
case ctx.Bool("force"):
286+
immediate = true
287+
}
288+
275289
resp, err := client.BumpFee(ctxc, &walletrpc.BumpFeeRequest{
276290
Outpoint: protoOutPoint,
277291
TargetConf: uint32(ctx.Uint64("conf_target")),
278-
Immediate: ctx.Bool("force"),
292+
Immediate: immediate,
279293
Budget: ctx.Uint64("budget"),
280294
})
281295
if err != nil {

docs/release-notes/release-notes-0.18.0.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,9 @@
127127
utxos which are unconfirmed and originated from the sweeper subsystem are not
128128
selected because they bear the risk of being replaced (BIP 125 RBF).
129129

130+
* [Fixed](https://github.com/lightningnetwork/lnd/pull/8685) lncli "bumpfee"
131+
parsing of the immediate/force flag.
132+
130133
# New Features
131134
## Functional Enhancements
132135

0 commit comments

Comments
 (0)