Merge pull request #9240 from carlaKC/9166-mergeonly

htlcswitch: merge htlc custom records on modify
This commit is contained in:
Elle authored and GitHub committed 2024-11-08 08:38:00 +02:00
commit 4430687076
5 files changed
+18 -19

No files matched your search

+6 -3
View File
@@ -715,9 +715,12 @@ func (f *interceptedForward) ResumeModified(
htlc.Amount = amount
})
if len(validatedRecords) > 0 {
htlc.CustomRecords = validatedRecords
}
// Merge custom records with any validated records that were
// added in the modify request, overwriting any existing values
// with those supplied in the modifier API.
htlc.CustomRecords = htlc.CustomRecords.MergedCopy(
validatedRecords,
)
case *lnwire.UpdateFulfillHTLC:
if len(validatedRecords) > 0 {