cmd/lncli: fix nil map in payment req [skip ci]

Fixes #5989.
Fixes a panic in lncli if a payment request and the --data flag is used
at the same time.
This commit is contained in:
Oliver Gugger
2021-11-16 13:51:05 +01:00
parent d45675d469
commit f65c259f06

View File

@@ -293,6 +293,7 @@ func sendPayment(ctx *cli.Context) error {
req := &routerrpc.SendPaymentRequest{
PaymentRequest: ctx.String("pay_req"),
Amt: ctx.Int64("amt"),
DestCustomRecords: make(map[uint64][]byte),
}
// We'll attempt to parse a payment address as well, given that