diff --git a/common/src/lib.rs b/common/src/lib.rs index a63b92779a..3514062143 100644 --- a/common/src/lib.rs +++ b/common/src/lib.rs @@ -162,6 +162,7 @@ pub enum ProxyType { SwapHotkey, SubnetLeaseBeneficiary, // Used to operate the leased subnet RootClaim, + Cancel, // For cancelling time-delayed proxy announcements } impl TryFrom for ProxyType { @@ -187,6 +188,7 @@ impl TryFrom for ProxyType { 15 => Ok(Self::SwapHotkey), 16 => Ok(Self::SubnetLeaseBeneficiary), 17 => Ok(Self::RootClaim), + 18 => Ok(Self::Cancel), _ => Err(()), } } @@ -213,6 +215,7 @@ impl From for u8 { ProxyType::SwapHotkey => 15, ProxyType::SubnetLeaseBeneficiary => 16, ProxyType::RootClaim => 17, + ProxyType::Cancel => 18, } } } diff --git a/runtime/src/lib.rs b/runtime/src/lib.rs index 41a00e3f64..178ffd61b2 100644 --- a/runtime/src/lib.rs +++ b/runtime/src/lib.rs @@ -779,6 +779,10 @@ impl InstanceFilter for ProxyType { c, RuntimeCall::SubtensorModule(pallet_subtensor::Call::claim_root { .. }) ), + ProxyType::Cancel => matches!( + c, + RuntimeCall::Proxy(pallet_proxy::Call::reject_announcement { .. }) + ), } } fn is_superset(&self, o: &Self) -> bool {