mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2026-01-30 11:24:23 +01:00
Remove possible NRE in the LightningListener
This commit is contained in:
@@ -144,6 +144,8 @@ retry:
|
||||
return _memoryCache.GetOrCreateAsync(GetCacheKey(invoiceId), async (cacheEntry) =>
|
||||
{
|
||||
var invoice = await _InvoiceRepository.GetInvoice(invoiceId);
|
||||
if (invoice is null)
|
||||
return null;
|
||||
cacheEntry.AbsoluteExpiration = GetExpiration(invoice);
|
||||
return invoice;
|
||||
})!;
|
||||
|
||||
Reference in New Issue
Block a user