mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-05-17 21:46:36 +00:00
Merge branch 'rpcfrontier' into develop
This commit is contained in:
commit
35bc7b0d8a
1 changed files with 7 additions and 1 deletions
|
|
@ -490,7 +490,13 @@ func (p *EthereumApi) GetRequestReply(req *RpcRequest, reply *interface{}) error
|
||||||
case "net_peerCount":
|
case "net_peerCount":
|
||||||
*reply = toHex(big.NewInt(int64(p.xeth().PeerCount())).Bytes())
|
*reply = toHex(big.NewInt(int64(p.xeth().PeerCount())).Bytes())
|
||||||
case "eth_coinbase":
|
case "eth_coinbase":
|
||||||
*reply = p.xeth().Coinbase()
|
// TODO handling of empty coinbase due to lack of accounts
|
||||||
|
res := p.xeth().Coinbase()
|
||||||
|
if res == "0x" || res == "0x0" {
|
||||||
|
*reply = nil
|
||||||
|
} else {
|
||||||
|
*reply = res
|
||||||
|
}
|
||||||
case "eth_mining":
|
case "eth_mining":
|
||||||
*reply = p.xeth().IsMining()
|
*reply = p.xeth().IsMining()
|
||||||
case "eth_gasPrice":
|
case "eth_gasPrice":
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue