mirror of
https://github.com/lightningnetwork/lnd.git
synced 2025-09-22 07:08:14 +02:00
htlcswitch: within handleLocalDispatch bubble up the decode error
This commit is contained in:
@@ -402,7 +402,12 @@ func (s *Switch) handleLocalDispatch(payment *pendingPayment, packet *htlcPacket
|
||||
}
|
||||
|
||||
// Notify user that his payment was discarded.
|
||||
payment.err <- failure
|
||||
if userErr != nil {
|
||||
payment.err <- userErr
|
||||
} else {
|
||||
payment.err <- failure
|
||||
}
|
||||
|
||||
payment.preimage <- zeroPreimage
|
||||
s.removePendingPayment(payment.amount, payment.paymentHash)
|
||||
|
||||
|
Reference in New Issue
Block a user