problem: chainId is not a string

rel: #22
This commit is contained in:
Igor Artamonov
2020-07-02 21:58:42 -04:00
parent a7fb805a03
commit fd070d5df4
2 changed files with 7 additions and 7 deletions

View File

@@ -129,16 +129,16 @@ class DefaultEthereumMethods(
"eth_chainId" -> {
when {
Chain.ETHEREUM == chain -> {
"0x0"
"\"0x0\""
}
Chain.ETHEREUM_CLASSIC == chain -> {
"0x3d"
"\"0x3d\""
}
Chain.TESTNET_MORDEN == chain -> {
"0x3c"
"\"0x3c\""
}
Chain.TESTNET_KOVAN == chain -> {
"0x2a"
"\"0x2a\""
}
else -> throw RpcException(-32602, "Invalid chain")
}