From 2db17cf21b669b417755360d23f8bc39351496fe Mon Sep 17 00:00:00 2001 From: Tymur Khrushchov Date: Mon, 22 Apr 2024 13:11:39 +0200 Subject: [PATCH] handle nil error --- core/sbundle_sim.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/core/sbundle_sim.go b/core/sbundle_sim.go index a90fddc8b..b56b63297 100644 --- a/core/sbundle_sim.go +++ b/core/sbundle_sim.go @@ -87,7 +87,9 @@ func SimBundle(config *params.ChainConfig, bc *BlockChain, author *common.Addres return res, err } res.Revert = result.Revert() - res.ExecError = result.Err.Error() + if result.Err != nil { + res.ExecError = result.Err.Error() + } if receipt.Status != types.ReceiptStatusSuccessful && !el.CanRevert { return res, ErrTxFailed }