From 39534ad6666226e8d1fb2cc472fff295a4259b52 Mon Sep 17 00:00:00 2001 From: coinplug-jhjin Date: Mon, 3 Apr 2023 13:32:01 +0900 Subject: [PATCH] internal/ethapi: changed 'gasPrice' data type to BigInt ('GetTransactionReceipt' RPC API). --- internal/ethapi/api.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/internal/ethapi/api.go b/internal/ethapi/api.go index 229e54ce4214..8e0f8bce242b 100644 --- a/internal/ethapi/api.go +++ b/internal/ethapi/api.go @@ -1667,14 +1667,14 @@ func (s *PublicTransactionPoolAPI) GetTransactionReceipt(ctx context.Context, ha } // Assign the effective gas price paid if !s.b.ChainConfig().IsLondon(bigblock) { - fields["effectiveGasPrice"] = hexutil.Uint64(tx.GasPrice().Uint64()) + fields["effectiveGasPrice"] = tx.GasPrice() } else { header, err := s.b.HeaderByHash(ctx, blockHash) if err != nil { return nil, err } gasPrice := new(big.Int).Add(header.BaseFee, tx.EffectiveGasTipValue(header.BaseFee)) - fields["effectiveGasPrice"] = hexutil.Uint64(gasPrice.Uint64()) + fields["effectiveGasPrice"] = gasPrice } // Assign receipt status or post state. if len(receipt.PostState) > 0 {