Skip to content

Commit

Permalink
BLOCKHASH reading past genesis is handled elsewhere, so handle actual…
Browse files Browse the repository at this point in the history
… errors
  • Loading branch information
axic committed Aug 18, 2017
1 parent 9812ee5 commit 9bf9f1d
Showing 1 changed file with 2 additions and 6 deletions.
8 changes: 2 additions & 6 deletions lib/opFns.js
Original file line number Diff line number Diff line change
Expand Up @@ -312,12 +312,8 @@ module.exports = {
}

stateManager.getBlockHash(number, function (err, blockHash) {
if (err) {
// if we are at a low block height and request a blockhash before the genesis block
cb(null, Buffer.from([0]))
} else {
cb(null, blockHash)
}
if (err) return cb(err)
cb(null, blockHash)
})
},
COINBASE: function (runState) {
Expand Down

0 comments on commit 9bf9f1d

Please sign in to comment.