From 9d59635b427f4a2f827b5dc48d1ca99ef5931f0a Mon Sep 17 00:00:00 2001 From: Steven Allen Date: Wed, 30 Sep 2020 15:04:16 -0700 Subject: [PATCH] fix error messages --- chain/stmgr/stmgr.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/chain/stmgr/stmgr.go b/chain/stmgr/stmgr.go index c5968c4a4..2ce393378 100644 --- a/chain/stmgr/stmgr.go +++ b/chain/stmgr/stmgr.go @@ -280,7 +280,7 @@ func (sm *StateManager) ApplyBlocks(ctx context.Context, parentEpoch abi.ChainEp sysAct, actErr := vmi.StateTree().GetActor(builtin0.SystemActorAddr) if actErr != nil { - return cid.Undef, cid.Undef, xerrors.Errorf("failed to get system actor: %w", err) + return cid.Undef, cid.Undef, xerrors.Errorf("failed to get system actor: %w", actErr) } rwMsg := &types.Message{ @@ -296,7 +296,7 @@ func (sm *StateManager) ApplyBlocks(ctx context.Context, parentEpoch abi.ChainEp } ret, actErr := vmi.ApplyImplicitMessage(ctx, rwMsg) if actErr != nil { - return cid.Undef, cid.Undef, xerrors.Errorf("failed to apply reward message for miner %s: %w", b.Miner, err) + return cid.Undef, cid.Undef, xerrors.Errorf("failed to apply reward message for miner %s: %w", b.Miner, actErr) } if cb != nil { if err := cb(rwMsg.Cid(), rwMsg, ret); err != nil {