From b412dcd29c73cc823a4346e1a060c52762a0b17e Mon Sep 17 00:00:00 2001 From: devwckd Date: Wed, 8 Jan 2025 15:09:34 -0300 Subject: [PATCH] feat: increment storages on registration --- pallets/torus0/src/agent.rs | 3 +++ 1 file changed, 3 insertions(+) diff --git a/pallets/torus0/src/agent.rs b/pallets/torus0/src/agent.rs index d2cd1b2..6120e38 100644 --- a/pallets/torus0/src/agent.rs +++ b/pallets/torus0/src/agent.rs @@ -113,6 +113,9 @@ pub fn register( }, ); + crate::RegistrationsThisBlock::::mutate(|value| value.saturating_add(1)); + crate::RegistrationsThisInterval::::mutate(|value| value.saturating_add(1)); + crate::Pallet::::deposit_event(crate::Event::::AgentRegistered(agent_key)); Ok(())