mirror of
https://github.com/JKorf/CryptoExchange.Net
synced 2025-06-06 23:46:12 +00:00
Fix for unnecessary error message in logging when closing connection
This commit is contained in:
parent
4bdad7fe0c
commit
fd1ec17d72
@ -604,7 +604,7 @@ namespace CryptoExchange.Net.Sockets
|
||||
}
|
||||
catch (Exception wse)
|
||||
{
|
||||
if (!_ctsSource.Token.IsCancellationRequested)
|
||||
if (!_ctsSource.Token.IsCancellationRequested && !_stopRequested)
|
||||
// Connection closed unexpectedly
|
||||
await (OnError?.Invoke(wse) ?? Task.CompletedTask).ConfigureAwait(false);
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user