From c80bd167a66612daaa390f9f9d4a0c0640739df8 Mon Sep 17 00:00:00 2001 From: 4tochka Date: Fri, 3 May 2019 16:08:26 +0400 Subject: [PATCH] connector --- pybtc/connector.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pybtc/connector.py b/pybtc/connector.py index ca20784..8518d8a 100644 --- a/pybtc/connector.py +++ b/pybtc/connector.py @@ -748,8 +748,8 @@ class UTXO(): async def save_utxo(self, block_height): # save to db tail from cache block_height -= self.maturity - if block_height > 0 and not self.save_process: - c = len(self.cached) - self._cache_size + c = len(self.cached) - self._cache_size + if block_height > 0 and not self.save_process and c > 0: try: self.save_process = True k = []