mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-11-21 19:50:05 +01:00
lncli: fix command line argument parsing for sendpayment
This commit fixes a bug that caused the payment hash to be (re)parsed as an int representing the final cltv delta.
This commit is contained in:
@@ -2121,6 +2121,7 @@ func sendPayment(ctx *cli.Context) error {
|
|||||||
rHash, err = hex.DecodeString(ctx.String("payment_hash"))
|
rHash, err = hex.DecodeString(ctx.String("payment_hash"))
|
||||||
case args.Present():
|
case args.Present():
|
||||||
rHash, err = hex.DecodeString(args.First())
|
rHash, err = hex.DecodeString(args.First())
|
||||||
|
args = args.Tail()
|
||||||
default:
|
default:
|
||||||
return fmt.Errorf("payment hash argument missing")
|
return fmt.Errorf("payment hash argument missing")
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user