lncli/bugfix: use int64slice for update node announcement features

As is, we'll never get any add/remove features because the flag is
set as an int 64 slice but accessed as an int slice (which has no
value, and the cli doesn't fail if the flag doesn't exist).
This commit is contained in:
Carla Kirk-Cohen committed 2023-02-14 15:53:56 -05:00
1 parent f245591e4b
commit 3cc8e81121
1 file changed
+2 -2
+2 -2
View File
@@ -126,7 +126,7 @@ func updateNodeAnnouncement(ctx *cli.Context) error {
if ctx.IsSet("feature_bit_add") {
change = true
for _, feature := range ctx.IntSlice("feature_bit_add") {
for _, feature := range ctx.Int64Slice("feature_bit_add") {
action := &peersrpc.UpdateFeatureAction{
Action: peersrpc.UpdateAction_ADD,
FeatureBit: lnrpc.FeatureBit(feature),
@@ -137,7 +137,7 @@ func updateNodeAnnouncement(ctx *cli.Context) error {
if ctx.IsSet("feature_bit_remove") {
change = true
for _, feature := range ctx.IntSlice("feature_bit_remove") {
for _, feature := range ctx.Int64Slice("feature_bit_remove") {
action := &peersrpc.UpdateFeatureAction{
Action: peersrpc.UpdateAction_REMOVE,
FeatureBit: lnrpc.FeatureBit(feature),