Skip to content

Commit 3230136

Browse files
author
unconst
committed
moving price init from emission
1 parent a16dbb8 commit 3230136

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pallets/subtensor/src/migrations/migrate_rao.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ use alloc::string::String;
33
use frame_support::IterableStorageMap;
44
use frame_support::{traits::Get, weights::Weight};
55
use sp_runtime::format;
6+
use substrate_fixed::types::I96F32;
67
use substrate_fixed::types::U64F64;
78

89
use super::*;
@@ -88,6 +89,7 @@ pub fn migrate_rao<T: Config>() -> Weight {
8889

8990
let remaining_lock = lock.saturating_sub(pool_initial_tao);
9091
// Refund the owner for the remaining lock.
92+
SubnetMovingPrice::<T>::insert(netuid, I96F32::from_num( EmissionValues::<T>::get(netuid) ) );
9193
Pallet::<T>::add_balance_to_coldkey_account(&owner, remaining_lock);
9294
SubnetLocked::<T>::insert(netuid, 0); // Clear lock amount.
9395
SubnetTAO::<T>::insert(netuid, pool_initial_tao);

0 commit comments

Comments
 (0)