diff --git a/BTCPayServer/Payments/Bitcoin/NBXplorerListener.cs b/BTCPayServer/Payments/Bitcoin/NBXplorerListener.cs index c1efc9d47..f5c936301 100644 --- a/BTCPayServer/Payments/Bitcoin/NBXplorerListener.cs +++ b/BTCPayServer/Payments/Bitcoin/NBXplorerListener.cs @@ -383,11 +383,12 @@ namespace BTCPayServer.Payments.Bitcoin _Aggregator.Publish(new InvoiceEvent(invoice, 1002, InvoiceEvent.ReceivedPayment){Payment = payment}); return invoice; } - public Task StopAsync(CancellationToken cancellationToken) + public async Task StopAsync(CancellationToken cancellationToken) { leases.Dispose(); _Cts.Cancel(); - return Task.WhenAny(_RunningTask.Task, Task.Delay(-1, cancellationToken)); + await Task.WhenAny(_RunningTask.Task, Task.Delay(-1, cancellationToken)); + Logs.PayServer.LogInformation($"{this.GetType().Name} successfully exited..."); } } } diff --git a/BTCPayServer/Payments/Lightning/LightningListener.cs b/BTCPayServer/Payments/Lightning/LightningListener.cs index 57101a677..dfc56e5d8 100644 --- a/BTCPayServer/Payments/Lightning/LightningListener.cs +++ b/BTCPayServer/Payments/Lightning/LightningListener.cs @@ -195,7 +195,7 @@ namespace BTCPayServer.Payments.Lightning { } - Logs.PayServer.LogInformation("Lightning listened stopped"); + Logs.PayServer.LogInformation($"{this.GetType().Name} successfully exited..."); } }