From 29340b692a94e71fa01be3fcf4fa41f47fb35187 Mon Sep 17 00:00:00 2001 From: "shiki.takahashi" Date: Tue, 19 Jul 2022 16:24:34 +0900 Subject: [PATCH] Remove unnecessary error check --- x/wasm/keeper/proposal_handler.go | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/x/wasm/keeper/proposal_handler.go b/x/wasm/keeper/proposal_handler.go index 9da330ce..6d99fb36 100644 --- a/x/wasm/keeper/proposal_handler.go +++ b/x/wasm/keeper/proposal_handler.go @@ -107,9 +107,7 @@ func handleMigrateProposal(ctx sdk.Context, k types.ContractOpsKeeper, p types.M if err != nil { return sdkerrors.Wrap(err, "contract") } - if err != nil { - return sdkerrors.Wrap(err, "run as address") - } + // runAs is not used if this is permissioned, so just put any valid address there (second contractAddr) data, err := k.Migrate(ctx, contractAddr, contractAddr, p.CodeID, p.Msg) if err != nil {