From 09f65bc0795e08d04bda7c4b710b2a23be13ec10 Mon Sep 17 00:00:00 2001 From: lightclient <14004106+lightclient@users.noreply.github.com> Date: Thu, 7 Jul 2022 14:50:28 -0500 Subject: [PATCH] internal/ethapi: fix chain ID check to return all non-zero IDs (#25244) --- internal/ethapi/api.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/ethapi/api.go b/internal/ethapi/api.go index 2b25c1045fc14..31151a819a7fd 100644 --- a/internal/ethapi/api.go +++ b/internal/ethapi/api.go @@ -1441,7 +1441,7 @@ func newRPCTransaction(tx *types.Transaction, blockHash common.Hash, blockNumber switch tx.Type() { case types.LegacyTxType: // if a legacy transaction has an EIP-155 chain id, include it explicitly - if id := tx.ChainId(); id.Sign() == 0 { + if id := tx.ChainId(); id.Sign() != 0 { result.ChainID = (*hexutil.Big)(id) } case types.AccessListTxType: