mirror of
https://github.com/aljazceru/btcpayserver.git
synced 2026-01-08 08:34:25 +01:00
Don't send mail for expired invoices
This commit is contained in:
@@ -118,7 +118,7 @@ namespace BTCPayServer.HostedServices
|
||||
#pragma warning restore CS0618
|
||||
}
|
||||
|
||||
if (!String.IsNullOrEmpty(invoice.NotificationEmail))
|
||||
if (invoiceEvent.Name != InvoiceEvent.Expired && !String.IsNullOrEmpty(invoice.NotificationEmail))
|
||||
{
|
||||
var emailBody = NBitcoin.JsonConverters.Serializer.ToString(notification);
|
||||
|
||||
@@ -126,7 +126,6 @@ namespace BTCPayServer.HostedServices
|
||||
invoice.NotificationEmail,
|
||||
$"BtcPayServer Invoice Notification - ${invoice.StoreId}",
|
||||
emailBody);
|
||||
|
||||
}
|
||||
|
||||
if (invoice.NotificationURL != null)
|
||||
|
||||
Reference in New Issue
Block a user