Skip to content

Commit ae8ce72

Browse files
authored
internal/ethapi: fix chain ID check to return all non-zero IDs (#25244)
1 parent e394d01 commit ae8ce72

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

internal/ethapi/api.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1290,7 +1290,7 @@ func newRPCTransaction(tx *types.Transaction, blockHash common.Hash, blockNumber
12901290
switch tx.Type() {
12911291
case types.LegacyTxType:
12921292
// if a legacy transaction has an EIP-155 chain id, include it explicitly
1293-
if id := tx.ChainId(); id.Sign() == 0 {
1293+
if id := tx.ChainId(); id.Sign() != 0 {
12941294
result.ChainID = (*hexutil.Big)(id)
12951295
}
12961296
case types.AccessListTxType:

0 commit comments

Comments
 (0)