Skip to content
This repository has been archived by the owner on Feb 26, 2024. It is now read-only.

Handle invalid block numbers in eth_getTransactionCount #291

Merged
merged 2 commits into from
Feb 20, 2019
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 2 additions & 0 deletions lib/blockchain_double.js
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,8 @@ BlockchainDouble.prototype.getBlock = function(number, callback) {
return this.latestBlock(callback);
} else if (number === "earliest") {
return this.data.blocks.first(callback);
} else {
process.nextTick(callback, new Error("Invalid `blockNumber`: \"" + number + "\""));
}
}
};
Expand Down