From 5a65b072528cc2152e1881e3c21b5dda08f99259 Mon Sep 17 00:00:00 2001 From: srdtrk <59252793+srdtrk@users.noreply.github.com> Date: Tue, 18 Jun 2024 19:51:30 +0200 Subject: [PATCH] imp: mark 'IcaQueryResponse' non_exhaustive and remove 'staking' feature gate (#123) * imp: removed some feature gating * imp: added more 'non_exhaustive' --- src/types/query_msg.rs | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/src/types/query_msg.rs b/src/types/query_msg.rs index 12d7f1b9..9dbc32ca 100644 --- a/src/types/query_msg.rs +++ b/src/types/query_msg.rs @@ -106,6 +106,7 @@ mod response { } /// The response for a successful ICA query. + #[non_exhaustive] #[cw_serde] pub enum IcaQueryResponse { /// Response for a [`cosmwasm_std::BankQuery`]. @@ -119,11 +120,11 @@ mod response { path: String, }, /// Response for a [`cosmwasm_std::StakingQuery`]. - #[cfg(feature = "staking")] Staking(StakingQueryResponse), } /// The response type for the [`cosmwasm_std::BankQuery`] queries. + #[non_exhaustive] #[cw_serde] pub enum BankQueryResponse { /// Response for the [`cosmwasm_std::BankQuery::Supply`] query. @@ -139,7 +140,7 @@ mod response { } /// The response type for the [`cosmwasm_std::StakingQuery`] queries. - #[cfg(feature = "staking")] + #[non_exhaustive] #[cw_serde] pub enum StakingQueryResponse { /// Response for the [`cosmwasm_std::StakingQuery::BondedDenom`] query. @@ -155,7 +156,6 @@ mod response { } /// Response for the [`cosmwasm_std::StakingQuery::Delegation`] query over ICA. - #[cfg(feature = "staking")] #[cw_serde] pub struct IcaDelegationResponse { /// The delegation response if it exists. @@ -163,7 +163,6 @@ mod response { } /// Response for the [`cosmwasm_std::StakingQuery::AllDelegations`] query over ICA. - #[cfg(feature = "staking")] #[cw_serde] pub struct IcaAllDelegationsResponse { /// The delegations. @@ -171,7 +170,6 @@ mod response { } /// Delegation is the detailed information about a delegation. - #[cfg(feature = "staking")] #[cw_serde] pub struct Delegation { /// The delegator address.