From 8de3825f1123cf9ce2d54d904b6fe9019d587f3c Mon Sep 17 00:00:00 2001 From: Alan Orwick Date: Tue, 11 Jul 2023 12:26:03 -0500 Subject: [PATCH] fix: estimate gas pendingBlock to latestBlock --- internal/quaiapi/quai_api.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/quaiapi/quai_api.go b/internal/quaiapi/quai_api.go index ae42089cb8..64c3179ace 100644 --- a/internal/quaiapi/quai_api.go +++ b/internal/quaiapi/quai_api.go @@ -409,7 +409,7 @@ func (s *PublicBlockChainQuaiAPI) EstimateGas(ctx context.Context, args Transact if nodeCtx != common.ZONE_CTX { return 0, errors.New("estimateGas can only called in a zone chain") } - bNrOrHash := rpc.BlockNumberOrHashWithNumber(rpc.PendingBlockNumber) + bNrOrHash := rpc.BlockNumberOrHashWithNumber(rpc.LatestBlockNumber) if blockNrOrHash != nil { bNrOrHash = *blockNrOrHash }