Skip to content
This repository has been archived by the owner on Aug 9, 2021. It is now read-only.

Commit

Permalink
Bugfix: eth_getCode add second parameter "latest"
Browse files Browse the repository at this point in the history
with it infura "Geth/v1.8.27-omnibus-c94f741c/linux-amd64/go1.11.1" returns an error:
"code": -32602, "message": "missing value for required argument 1"
Parity seems to have no problem with the missing parameter
  • Loading branch information
PeterTheOne authored and oed committed Nov 25, 2019
1 parent 09fcd90 commit 8b4ad7c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/utils/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -124,7 +124,7 @@ module.exports = {

getCode: async (ethereumProvider, address) => {
const method = 'eth_getCode'
const params = [address]
const params = [address, 'latest']

const code = await safeSend(ethereumProvider, {
jsonrpc: '2.0',
Expand Down

0 comments on commit 8b4ad7c

Please sign in to comment.