1
0
mirror of https://github.com/JKorf/CryptoExchange.Net synced 2025-06-08 16:36:15 +00:00

Update SymbolOrderBook.cs

This commit is contained in:
Jkorf 2021-02-16 15:32:29 +01:00
parent 396b9c736e
commit 8e97a7f3ae

View File

@ -402,7 +402,19 @@ namespace CryptoExchange.Net.OrderBook
{
lock (bookLock)
{
var checksumResult = DoChecksum(ci.Checksum);
bool checksumResult = false;
try
{
checksumResult = DoChecksum(ci.Checksum);
}
catch (Exception)
{
// If the status is not synced it can be expected a checksum is failing
if (Status == OrderBookStatus.Synced)
throw;
}
if(!checksumResult)
{
log.Write(LogVerbosity.Warning, $"{Id} order book {Symbol} out of sync. Resyncing");