From 08bb9a8454b6bf351e01c923acc66c48f05ce472 Mon Sep 17 00:00:00 2001 From: Bulat Ziganshin Date: Thu, 30 Jun 2022 15:52:31 +0300 Subject: [PATCH] DEBUG: check CacheStore.getBlock with catch --- codex/stores/cachestore.nim | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/codex/stores/cachestore.nim b/codex/stores/cachestore.nim index 7ac6fa05..1236c7db 100644 --- a/codex/stores/cachestore.nim +++ b/codex/stores/cachestore.nim @@ -58,7 +58,7 @@ method getBlock*( if cid notin self.cache: return Block.failure("Block not found") # TODO: return nil - return self.cache[cid] + return self.cache[cid].catch() method hasBlock*(self: CacheStore, cid: Cid): Future[?!bool] {.async.} = ## Check if the block exists in the blockstore