Skip to content

Commit

Permalink
eth/client: fix get balance for block number
Browse files Browse the repository at this point in the history
Add availability to request `eth_get_balance` for the block number
  • Loading branch information
dapi authored Apr 2, 2024
1 parent db8becd commit 6588866
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/eth/client.rb
Original file line number Diff line number Diff line change
Expand Up @@ -469,7 +469,7 @@ def encode_constructor_params(contract, args)

# Prepares parameters and sends the command to the client.
def send_command(command, args)
args << "latest" if ["eth_getBalance", "eth_call"].include? command
args << "latest" if ["eth_getBalance", "eth_call"].include?(command) && args.count == 1
payload = {
jsonrpc: "2.0",
method: command,
Expand Down

0 comments on commit 6588866

Please sign in to comment.