diff --git a/contracts/consumer/converter/src/ibc.rs b/contracts/consumer/converter/src/ibc.rs index e81006c5..d711a2a5 100644 --- a/contracts/consumer/converter/src/ibc.rs +++ b/contracts/consumer/converter/src/ibc.rs @@ -188,7 +188,7 @@ pub fn ibc_packet_receive( _env: Env, msg: IbcPacketReceiveMsg, ) -> Result { - let packet: ProviderPacket = from_json(&msg.packet.data)?; + let packet: ProviderPacket = from_json(msg.packet.data)?; let contract = ConverterContract::new(); let res = match packet { ProviderPacket::Stake { diff --git a/contracts/consumer/remote-price-feed/src/ibc.rs b/contracts/consumer/remote-price-feed/src/ibc.rs index 8124079c..43c4ef69 100644 --- a/contracts/consumer/remote-price-feed/src/ibc.rs +++ b/contracts/consumer/remote-price-feed/src/ibc.rs @@ -125,7 +125,7 @@ pub fn ibc_packet_ack( _env: Env, msg: IbcPacketAckMsg, ) -> Result { - let ack: PriceFeedProviderAck = from_json(&msg.acknowledgement.data)?; + let ack: PriceFeedProviderAck = from_json(msg.acknowledgement.data)?; let PriceFeedProviderAck::Update { time, twap } = ack; let contract = RemotePriceFeedContract::new(); contract.update_twap(deps, time, twap)?; diff --git a/contracts/osmosis-price-provider/src/ibc.rs b/contracts/osmosis-price-provider/src/ibc.rs index 94116910..d7871e65 100644 --- a/contracts/osmosis-price-provider/src/ibc.rs +++ b/contracts/osmosis-price-provider/src/ibc.rs @@ -124,7 +124,7 @@ pub fn ibc_packet_receive( pool_id, base_asset, quote_asset, - } = from_json(&msg.packet.data)?; + } = from_json(msg.packet.data)?; let contract = OsmosisPriceProvider::new(); let time = env.block.time; diff --git a/contracts/provider/external-staking/src/contract.rs b/contracts/provider/external-staking/src/contract.rs index 50d8e7e2..0ac1c833 100644 --- a/contracts/provider/external-staking/src/contract.rs +++ b/contracts/provider/external-staking/src/contract.rs @@ -865,6 +865,7 @@ impl ExternalStakingContract<'_> { /// In test code, this is called from `test_handle_slashing`. /// In non-test code, this is being called from `ibc_packet_receive` (in the `ConsumerPacket::RemoveValidators` /// handler) + #[allow(clippy::too_many_arguments)] pub(crate) fn handle_slashing( &self, env: &Env, @@ -1236,7 +1237,7 @@ pub mod cross_staking { let owner = ctx.deps.api.addr_validate(&owner)?; // parse and validate message - let msg: ReceiveVirtualStake = from_json(&msg)?; + let msg: ReceiveVirtualStake = from_json(msg)?; if !self .val_set .is_active_validator(ctx.deps.storage, &msg.validator)? diff --git a/contracts/provider/external-staking/src/ibc.rs b/contracts/provider/external-staking/src/ibc.rs index 2672b90d..69127f2d 100644 --- a/contracts/provider/external-staking/src/ibc.rs +++ b/contracts/provider/external-staking/src/ibc.rs @@ -123,7 +123,7 @@ pub fn ibc_packet_receive( // If a validator is in more than one of the events, the end result will depend on the // processing order below. let contract = ExternalStakingContract::new(); - let packet: ConsumerPacket = from_json(&msg.packet.data)?; + let packet: ConsumerPacket = from_json(msg.packet.data)?; let resp = match packet { ConsumerPacket::ValsetUpdate { height, @@ -251,7 +251,7 @@ pub fn ibc_packet_timeout( _env: Env, msg: IbcPacketTimeoutMsg, ) -> Result { - let packet: ProviderPacket = from_json(&msg.packet.data)?; + let packet: ProviderPacket = from_json(msg.packet.data)?; let contract = ExternalStakingContract::new(); let mut resp = IbcBasicResponse::new().add_attribute("action", "ibc_packet_timeout"); match packet { diff --git a/contracts/provider/native-staking/src/contract.rs b/contracts/provider/native-staking/src/contract.rs index 3aa562a7..592928c4 100644 --- a/contracts/provider/native-staking/src/contract.rs +++ b/contracts/provider/native-staking/src/contract.rs @@ -200,7 +200,7 @@ impl NativeStakingContract<'_> { // Associate staking proxy with owner address let proxy_addr = Addr::unchecked(init_data.contract_address); let owner_data: OwnerMsg = - from_json(&init_data.data.ok_or(ContractError::NoInstantiateData {})?)?; + from_json(init_data.data.ok_or(ContractError::NoInstantiateData {})?)?; let owner_addr = deps.api.addr_validate(&owner_data.owner)?; self.proxy_by_owner .save(deps.storage, &owner_addr, &proxy_addr)?; diff --git a/contracts/provider/native-staking/src/local_staking_api.rs b/contracts/provider/native-staking/src/local_staking_api.rs index 3d9d5a27..41ae02ac 100644 --- a/contracts/provider/native-staking/src/local_staking_api.rs +++ b/contracts/provider/native-staking/src/local_staking_api.rs @@ -37,7 +37,7 @@ impl LocalStakingApi for NativeStakingContract<'_> { let _paid = must_pay(&ctx.info, &cfg.denom)?; // Parse message to find validator to stake on - let StakeMsg { validator } = from_json(&msg)?; + let StakeMsg { validator } = from_json(msg)?; let owner_addr = ctx.deps.api.addr_validate(&owner)?;