From 6e44165b5117a2d07f141d1b83f6ca5c7e10a08b Mon Sep 17 00:00:00 2001 From: Anthony Laibe <491074+alaibe@users.noreply.github.com> Date: Thu, 7 Mar 2024 12:05:53 +0100 Subject: [PATCH] fix: sepolia balance --- rpc/chain/client.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/rpc/chain/client.go b/rpc/chain/client.go index 26b757ccc..865b1c887 100644 --- a/rpc/chain/client.go +++ b/rpc/chain/client.go @@ -88,8 +88,6 @@ var propagateErrors = []error{ vm.ErrInvalidCode, vm.ErrNonceUintOverflow, - core.ErrInsufficientFunds, - // Used by balance history to check state ethereum.NotFound, bind.ErrNoCode, @@ -161,10 +159,14 @@ func isVMError(err error) bool { if strings.HasPrefix(err.Error(), "execution reverted") { return true } + if strings.Contains(err.Error(), core.ErrInsufficientFunds.Error()) { + return true + } for _, vmError := range propagateErrors { - if err == vmError || strings.Contains(err.Error(), vmError.Error()) { + if err == vmError { return true } + } return false }