lncli: allow setting max local csv for open channel requests

This commit is contained in:
carla 2020-10-29 11:29:57 +02:00
parent 91bf59df17
commit f1aa3d2071
No known key found for this signature in database
GPG Key ID: 4CA7FE54A6213C91

@ -135,6 +135,13 @@ var openChannelCommand = cli.Command{
"not set, we will scale the value according to the " + "not set, we will scale the value according to the " +
"channel size", "channel size",
}, },
cli.Uint64Flag{
Name: "max_local_csv",
Usage: "(optional) the maximum number of blocks that " +
"we will allow the remote peer to require we " +
"wait before accessing our funds in the case " +
"of a unilateral close.",
},
cli.Uint64Flag{ cli.Uint64Flag{
Name: "min_confs", Name: "min_confs",
Usage: "(optional) the minimum number of confirmations " + Usage: "(optional) the minimum number of confirmations " +
@ -207,6 +214,7 @@ func openChannel(ctx *cli.Context) error {
SpendUnconfirmed: minConfs == 0, SpendUnconfirmed: minConfs == 0,
CloseAddress: ctx.String("close_address"), CloseAddress: ctx.String("close_address"),
RemoteMaxValueInFlightMsat: ctx.Uint64("remote_max_value_in_flight_msat"), RemoteMaxValueInFlightMsat: ctx.Uint64("remote_max_value_in_flight_msat"),
MaxLocalCsv: uint32(ctx.Uint64("max_local_csv")),
} }
switch { switch {