@@ -44,7 +44,7 @@ mod registration;
44
44
mod root;
45
45
mod serving;
46
46
mod staking;
47
- mod swap ;
47
+ mod swap_coldkey ;
48
48
mod swap_hotkey;
49
49
mod uids;
50
50
mod utils;
@@ -726,7 +726,7 @@ pub mod pallet {
726
726
#[ pallet:: storage] // --- MAP ( netuid ) --> last_mechanism_step_block
727
727
pub type LastMechansimStepBlock < T > =
728
728
StorageMap < _ , Identity , u16 , u64 , ValueQuery , DefaultLastMechanismStepBlock < T > > ;
729
- #[ pallet:: storage] // --- MAP ( netuid ) --> subnet_owner
729
+ #[ pallet:: storage] // --- MAP ( netuid ) --> (cold) subnet_owner
730
730
pub type SubnetOwner < T : Config > =
731
731
StorageMap < _ , Identity , u16 , T :: AccountId , ValueQuery , DefaultSubnetOwner < T > > ;
732
732
#[ pallet:: storage] // --- MAP ( netuid ) --> subnet_locked
@@ -801,10 +801,10 @@ pub mod pallet {
801
801
#[ pallet:: storage] // --- ITEM ( tx_rate_limit )
802
802
pub type TxDelegateTakeRateLimit < T > =
803
803
StorageValue < _ , u64 , ValueQuery , DefaultTxDelegateTakeRateLimit < T > > ;
804
- #[ pallet:: storage] // --- MAP ( key ) --> last_block
804
+ #[ pallet:: storage] // --- MAP ( hotkey ) --> last_block
805
805
pub type LastTxBlock < T : Config > =
806
806
StorageMap < _ , Identity , T :: AccountId , u64 , ValueQuery , DefaultLastTxBlock < T > > ;
807
- #[ pallet:: storage] // --- MAP ( key ) --> last_block
807
+ #[ pallet:: storage] // --- MAP ( hotkey ) --> last_block
808
808
pub type LastTxBlockDelegateTake < T : Config > =
809
809
StorageMap < _ , Identity , T :: AccountId , u64 , ValueQuery , DefaultLastTxBlock < T > > ;
810
810
@@ -2065,17 +2065,17 @@ pub mod pallet {
2065
2065
}
2066
2066
2067
2067
/// The extrinsic for user to change its hotkey
2068
- /// #[pallet::call_index(70)]
2069
- /// #[pallet::weight((Weight::from_parts(1_940_000_000, 0)
2070
- /// .saturating_add(T::DbWeight::get().reads(272))
2071
- /// .saturating_add(T::DbWeight::get().writes(527)), DispatchClass::Operational, Pays::No))]
2072
- /// pub fn swap_hotkey(
2073
- /// origin: OriginFor<T>,
2074
- /// hotkey: T::AccountId,
2075
- /// new_hotkey: T::AccountId,
2076
- /// ) -> DispatchResultWithPostInfo {
2077
- /// Self::do_swap_hotkey(origin, &hotkey, &new_hotkey)
2078
- /// }
2068
+ #[ pallet:: call_index( 70 ) ]
2069
+ #[ pallet:: weight( ( Weight :: from_parts( 1_940_000_000 , 0 )
2070
+ . saturating_add( T :: DbWeight :: get( ) . reads( 272 ) )
2071
+ . saturating_add( T :: DbWeight :: get( ) . writes( 527 ) ) , DispatchClass :: Operational , Pays :: No ) ) ]
2072
+ pub fn swap_hotkey (
2073
+ origin : OriginFor < T > ,
2074
+ hotkey : T :: AccountId ,
2075
+ new_hotkey : T :: AccountId ,
2076
+ ) -> DispatchResultWithPostInfo {
2077
+ Self :: do_swap_hotkey ( origin, & hotkey, & new_hotkey)
2078
+ }
2079
2079
2080
2080
/// The extrinsic for user to change the coldkey associated with their account.
2081
2081
///
0 commit comments