diff --git a/pallets/subtensor/src/coinbase/run_coinbase.rs b/pallets/subtensor/src/coinbase/run_coinbase.rs index 60abfd1145..ebb009937b 100644 --- a/pallets/subtensor/src/coinbase/run_coinbase.rs +++ b/pallets/subtensor/src/coinbase/run_coinbase.rs @@ -30,8 +30,8 @@ impl Pallet { ); // Reset per-block root sell counters from the previous block. - // Root sells (step 8 in block_step) happen after coinbase, so their - // accumulated values are consumed here at the start of the next block. + // Root sells happen after coinbase, so their accumulated values + // are consumed here at the start of the next block. let _ = SubnetRootSellTao::::clear(u32::MAX, None); // --- 1. Get all subnets (excluding root). diff --git a/pallets/subtensor/src/coinbase/subnet_emissions.rs b/pallets/subtensor/src/coinbase/subnet_emissions.rs index 44f7cdb163..485e2cf662 100644 --- a/pallets/subtensor/src/coinbase/subnet_emissions.rs +++ b/pallets/subtensor/src/coinbase/subnet_emissions.rs @@ -67,7 +67,7 @@ impl Pallet { SubnetProtocolFlow::::remove(netuid); } - fn get_ema_protocol_flow(netuid: NetUid) -> I64F64 { + fn update_ema_protocol_flow(netuid: NetUid) -> I64F64 { let current_block: u64 = Self::get_current_block_as_u64(); let block_flow = I64F64::saturating_from_num(SubnetProtocolFlow::::get(netuid)); @@ -223,8 +223,8 @@ impl Pallet { .iter() .map(|netuid| { let user_ema = Self::get_ema_flow(*netuid); - let protocol_ema = Self::get_ema_protocol_flow(*netuid); let net = if net_flow_enabled { + let protocol_ema = Self::update_ema_protocol_flow(*netuid); user_ema.saturating_sub(protocol_ema) } else { user_ema