From 3c6ace86493662556de0dff4bd5e2208b5b75855 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C4=90=E1=BB=97=20Vi=E1=BB=87t=20Ho=C3=A0ng?= Date: Fri, 22 Mar 2024 15:30:36 +0700 Subject: [PATCH] chore: remove deprecate uses of sdkerrors (#21) --- app/ante.go | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/app/ante.go b/app/ante.go index 15f4865..72e9ea5 100644 --- a/app/ante.go +++ b/app/ante.go @@ -9,6 +9,7 @@ import ( ibcante "github.com/cosmos/ibc-go/v6/modules/core/ante" ibckeeper "github.com/cosmos/ibc-go/v6/modules/core/keeper" + errorsmod "cosmossdk.io/errors" wasmkeeper "github.com/CosmWasm/wasmd/x/wasm/keeper" wasmtypes "github.com/CosmWasm/wasmd/x/wasm/types" ) @@ -58,19 +59,19 @@ func GetAnteDecorators(options HandlerOptions) []sdk.AnteDecorator { func NewAnteHandler(options HandlerOptions) (sdk.AnteHandler, error) { //From x/auth/ante.go if options.AccountKeeper == nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrLogic, "account keeper is required for ante builder") + return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "account keeper is required for ante builder") } if options.BankKeeper == nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrLogic, "bank keeper is required for ante builder") + return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "bank keeper is required for ante builder") } if options.SignModeHandler == nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrLogic, "sign mode handler is required for ante builder") + return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "sign mode handler is required for ante builder") } if options.WasmConfig == nil { - return nil, sdkerrors.Wrap(sdkerrors.ErrLogic, "wasm config is required for ante builder") + return nil, errorsmod.Wrap(sdkerrors.ErrLogic, "wasm config is required for ante builder") } return sdk.ChainAnteDecorators(GetAnteDecorators(options)...), nil