diff --git a/htlcswitch/link.go b/htlcswitch/link.go index 3be0c59eb..0c7f30663 100644 --- a/htlcswitch/link.go +++ b/htlcswitch/link.go @@ -1087,8 +1087,8 @@ func (l *channelLink) processLockedInHtlcs( case lnwallet.Add: // Fetch the onion blob that was included within this // processed payment descriptor. - onionBlob := l.clearedOnionBlobs[pd.Index] - delete(l.clearedOnionBlobs, pd.Index) + onionBlob := l.clearedOnionBlobs[pd.HtlcIndex] + delete(l.clearedOnionBlobs, pd.HtlcIndex) // Retrieve onion obfuscator from onion blob in order // to produce initial obfuscation of the onion