invoices: integrate settlement interceptor with invoice registry
This commit updates the invoice registry to utilize the settlement interceptor during the invoice settlement routine. It allows the interceptor to capture the invoice, providing interception clients an opportunity to determine the settlement outcome.
This commit is contained in:
1 parent
b8c8774b5d
commit
c58b6a25a2
4 files changed
+69
-4
No files matched your search
@@ -1014,6 +1014,7 @@ func newMockRegistry(minDelta uint32) *mockInvoiceRegistry {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
modifierMock := &invoices.MockHtlcModifier{}
|
||||
registry := invoices.NewRegistry(
|
||||
cdb,
|
||||
invoices.NewInvoiceExpiryWatcher(
|
||||
@@ -1022,6 +1023,7 @@ func newMockRegistry(minDelta uint32) *mockInvoiceRegistry {
|
||||
),
|
||||
&invoices.RegistryConfig{
|
||||
FinalCltvRejectDelta: 5,
|
||||
HtlcInterceptor: modifierMock,
|
||||
},
|
||||
)
|
||||
registry.Start()
|
||||
|
||||
Reference in new issue
Block a user