From 32a0c7bd1e67953f4e3e03fc88a63c45a0241c47 Mon Sep 17 00:00:00 2001 From: "will.li" <120463031+higherordertech@users.noreply.github.com> Date: Wed, 4 Sep 2024 21:28:54 +1000 Subject: [PATCH] feat: P-1006 add new Assertion enum item LinkedIdentities (#3042) Co-authored-by: higherordertech --- primitives/core/src/assertion/mod.rs | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/primitives/core/src/assertion/mod.rs b/primitives/core/src/assertion/mod.rs index fa263e0717..001f8484f5 100644 --- a/primitives/core/src/assertion/mod.rs +++ b/primitives/core/src/assertion/mod.rs @@ -139,7 +139,10 @@ pub enum Assertion { NftHolder(Web3NftType), #[codec(index = 27)] - Dynamic(DynamicParams) + Dynamic(DynamicParams), + + #[codec(index = 28)] + LinkedIdentities, } const A8_SUPPORTED_NETWORKS: [Web3Network; 5] = [ @@ -196,7 +199,11 @@ impl Assertion { // any web3 network is allowed Self::A1 | Self::A13(..) | Self::A20 => all_web3networks(), // no web3 network is allowed - Self::A2(..) | Self::A3(..) | Self::A6 | Self::GenericDiscordRole(..) => vec![], + Self::A2(..) + | Self::A3(..) + | Self::A6 + | Self::GenericDiscordRole(..) + | Self::LinkedIdentities => vec![], Self::TokenHoldingAmount(t_type) => t_type.get_supported_networks(), Self::PlatformUser(p_type) => p_type.get_supported_networks(), Self::NftHolder(t_type) => t_type.get_supported_networks(), @@ -209,7 +216,7 @@ impl Assertion { #[allow(clippy::match_like_matches_macro)] pub fn skip_identity_filtering(&self) -> bool { match self { - Self::A1 | Self::Dynamic(..) => true, + Self::A1 | Self::Dynamic(..) | Self::LinkedIdentities => true, _ => false, } }