Skip to content

Commit 52e2ff3

Browse files
committed
cln: Fix typo in probe payment
1 parent a6af654 commit 52e2ff3

File tree

1 file changed

+2
-6
lines changed

1 file changed

+2
-6
lines changed

clightning/clightning.go

+2-6
Original file line numberDiff line numberDiff line change
@@ -640,10 +640,6 @@ func (cl *ClightningClient) ProbePayment(scid string, amountMsat uint64) (bool,
640640
}
641641
}
642642

643-
route, err := cl.glightning.GetRoute(channel.PeerId, amountMsat, 1, 0, cl.nodeId, 0, nil, 1)
644-
if err != nil {
645-
return false, "", fmt.Errorf("GetRoute() %w", err)
646-
}
647643
preimage, err := lightning.GetPreimage()
648644
if err != nil {
649645
return false, "", fmt.Errorf("GetPreimage() %w", err)
@@ -677,8 +673,8 @@ func (cl *ClightningClient) ProbePayment(scid string, amountMsat uint64) (bool,
677673
if !ok {
678674
return false, "", fmt.Errorf("WaitSendPay() %w", err)
679675
}
680-
faiCodeWireIncorrectOrUnknownPaymentDetails := 203
681-
if pe.RpcError.Code != faiCodeWireIncorrectOrUnknownPaymentDetails {
676+
failCodeWireIncorrectOrUnknownPaymentDetails := 203
677+
if pe.RpcError.Code != failCodeWireIncorrectOrUnknownPaymentDetails {
682678
log.Debugf("send pay would be failed. reason:%w", err)
683679
return false, pe.Error(), nil
684680
}

0 commit comments

Comments
 (0)