From 1189e703da1a77733efa2b92fd669d0d182b5884 Mon Sep 17 00:00:00 2001 From: Olaoluwa Osuntokun Date: Tue, 10 Jul 2018 19:37:24 -0700 Subject: [PATCH] invoiceregistry: enforce stricter check on duplicate ntfn avoidance --- invoiceregistry.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/invoiceregistry.go b/invoiceregistry.go index 59c534d6e..be63ea268 100644 --- a/invoiceregistry.go +++ b/invoiceregistry.go @@ -144,13 +144,13 @@ func (i *invoiceRegistry) invoiceEventNotifier() { // If we've already sent this settle event to // the client, then we can skip this. case event.isSettle && - client.settleIndex == invoice.SettleIndex: + client.settleIndex >= invoice.SettleIndex: continue // Similarly, if we've already sent this add to // the client then we can skip this one. case !event.isSettle && - client.addIndex == invoice.AddIndex: + client.addIndex >= invoice.AddIndex: continue // These two states should never happen, but we