Merge pull request #4298 from cfromknecht/sub-inv-fixes
channeldb+invoices: minor invoice subscription fixes
This commit is contained in:
5 files changed
+41
-30
No files matched your search
+4
-1
@@ -4535,9 +4535,12 @@ func (r *rpcServer) ListInvoices(ctx context.Context,
|
||||
func (r *rpcServer) SubscribeInvoices(req *lnrpc.InvoiceSubscription,
|
||||
updateStream lnrpc.Lightning_SubscribeInvoicesServer) error {
|
||||
|
||||
invoiceClient := r.server.invoices.SubscribeNotifications(
|
||||
invoiceClient, err := r.server.invoices.SubscribeNotifications(
|
||||
req.AddIndex, req.SettleIndex,
|
||||
)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
defer invoiceClient.Cancel()
|
||||
|
||||
for {
|
||||
|
||||
Reference in new issue
Block a user