From ec00505cabd653577d9657621bda967e69f353d5 Mon Sep 17 00:00:00 2001 From: cubedro Date: Wed, 18 Feb 2015 12:02:27 +0200 Subject: [PATCH] fixed txCount for older nodes --- lib/node.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/node.js b/lib/node.js index 8e53ee7..2856723 100644 --- a/lib/node.js +++ b/lib/node.js @@ -160,7 +160,7 @@ Node.prototype.getBlock = function(number) block.difficulty = web3.toDecimal(block.difficulty); try { - block.txCount = web3.eth.transactionCount(block.hash); + block.txCount = web3.eth.transactionCount(block.hash) || '?'; } catch (err) { console.log(err);