lncli: add use_mc flag

This commit is contained in:
Joost Jager 2019-06-26 14:35:03 +02:00
parent fc337cd34f
commit 541e5f4af7
No known key found for this signature in database
GPG Key ID: A61B9D4C393C59C7

@ -2997,6 +2997,10 @@ var queryRoutesCommand = cli.Command{
Usage: "(optional) number of blocks the last hop has to reveal " + Usage: "(optional) number of blocks the last hop has to reveal " +
"the preimage", "the preimage",
}, },
cli.BoolFlag{
Name: "use_mc",
Usage: "use mission control probabilities",
},
}, },
Action: actionDecorator(queryRoutes), Action: actionDecorator(queryRoutes),
} }
@ -3042,10 +3046,11 @@ func queryRoutes(ctx *cli.Context) error {
} }
req := &lnrpc.QueryRoutesRequest{ req := &lnrpc.QueryRoutesRequest{
PubKey: dest, PubKey: dest,
Amt: amt, Amt: amt,
FeeLimit: feeLimit, FeeLimit: feeLimit,
FinalCltvDelta: int32(ctx.Int("final_cltv_delta")), FinalCltvDelta: int32(ctx.Int("final_cltv_delta")),
UseMissionControl: ctx.Bool("use_mc"),
} }
route, err := client.QueryRoutes(ctxb, req) route, err := client.QueryRoutes(ctxb, req)