diff --git a/ibc-clients/ics07-tendermint/cw-contract/src/entrypoint.rs b/ibc-clients/ics07-tendermint/cw-contract/src/entrypoint.rs index b496c97c1..e01e796b9 100644 --- a/ibc-clients/ics07-tendermint/cw-contract/src/entrypoint.rs +++ b/ibc-clients/ics07-tendermint/cw-contract/src/entrypoint.rs @@ -1,6 +1,4 @@ -use cosmwasm_std::{ - entry_point, Binary, Deps, DepsMut, Env, MessageInfo, Response, StdError, StdResult, -}; +use cosmwasm_std::{entry_point, Binary, Deps, DepsMut, Env, MessageInfo, Response}; use ibc_client_cw::context::Context; use ibc_client_cw::types::{ContractError, InstantiateMsg, QueryMsg, SudoMsg}; @@ -16,25 +14,19 @@ pub fn instantiate( msg: InstantiateMsg, ) -> Result { let mut ctx = TendermintContext::new_mut(deps, env)?; - let data = ctx.instantiate(msg)?; - Ok(Response::default().set_data(data)) } #[entry_point] pub fn sudo(deps: DepsMut<'_>, env: Env, msg: SudoMsg) -> Result { let mut ctx = TendermintContext::new_mut(deps, env)?; - let data = ctx.sudo(msg)?; - Ok(Response::default().set_data(data)) } #[entry_point] -pub fn query(deps: Deps<'_>, env: Env, msg: QueryMsg) -> StdResult { +pub fn query(deps: Deps<'_>, env: Env, msg: QueryMsg) -> Result { let ctx = TendermintContext::new_ref(deps, env)?; - ctx.query(msg) - .map_err(|e| StdError::generic_err(e.to_string())) }