File tree Expand file tree Collapse file tree 3 files changed +3
-4
lines changed
Expand file tree Collapse file tree 3 files changed +3
-4
lines changed Original file line number Diff line number Diff line change @@ -1231,7 +1231,7 @@ mod dispatches {
12311231 #[ pallet:: call_index( 59 ) ]
12321232 #[ pallet:: weight( ( Weight :: from_parts( 235_400_000 , 0 )
12331233 . saturating_add( T :: DbWeight :: get( ) . reads( 36_u64 ) )
1234- . saturating_add( T :: DbWeight :: get( ) . writes( 53_u64 ) ) , DispatchClass :: Normal , Pays :: Yes ) ) ]
1234+ . saturating_add( T :: DbWeight :: get( ) . writes( 52_u64 ) ) , DispatchClass :: Normal , Pays :: Yes ) ) ]
12351235 pub fn register_network ( origin : OriginFor < T > , hotkey : T :: AccountId ) -> DispatchResult {
12361236 Self :: do_register_network ( origin, & hotkey, 1 , None )
12371237 }
@@ -1519,7 +1519,7 @@ mod dispatches {
15191519 #[ pallet:: call_index( 79 ) ]
15201520 #[ pallet:: weight( ( Weight :: from_parts( 234_200_000 , 0 )
15211521 . saturating_add( T :: DbWeight :: get( ) . reads( 35_u64 ) )
1522- . saturating_add( T :: DbWeight :: get( ) . writes( 52_u64 ) ) , DispatchClass :: Normal , Pays :: Yes ) ) ]
1522+ . saturating_add( T :: DbWeight :: get( ) . writes( 51_u64 ) ) , DispatchClass :: Normal , Pays :: Yes ) ) ]
15231523 pub fn register_network_with_identity (
15241524 origin : OriginFor < T > ,
15251525 hotkey : T :: AccountId ,
Original file line number Diff line number Diff line change 11use super :: * ;
22use sp_core:: Get ;
33use subtensor_runtime_common:: { NetUid , TaoCurrency } ;
4- use subtensor_swap_interface:: SwapHandler ;
54impl < T : Config > Pallet < T > {
65 /// Returns true if the subnetwork exists.
76 ///
@@ -247,7 +246,6 @@ impl<T: Config> Pallet<T> {
247246 Self :: deposit_event ( Event :: SubnetIdentitySet ( netuid_to_register) ) ;
248247 }
249248
250- T :: SwapInterface :: toggle_user_liquidity ( netuid_to_register, true ) ;
251249 // --- 18. Emit the NetworkAdded event.
252250 log:: info!( "NetworkAdded( netuid:{netuid_to_register:?}, mechanism:{mechid:?} )" ) ;
253251 Self :: deposit_event ( Event :: NetworkAdded ( netuid_to_register, mechid) ) ;
Original file line number Diff line number Diff line change @@ -1820,6 +1820,7 @@ fn massive_dissolve_refund_and_reregistration_flow_is_lossless_and_cleans_state(
18201820 let ct = pallet_subtensor_swap:: CurrentTick :: < Test > :: get ( net) ;
18211821 let lo = ct. saturating_sub ( band) ;
18221822 let hi = ct. saturating_add ( band) ;
1823+ pallet_subtensor_swap:: EnabledUserLiquidity :: < Test > :: insert ( net, true ) ;
18231824 assert_ok ! ( pallet_subtensor_swap:: Pallet :: <Test >:: add_liquidity(
18241825 RuntimeOrigin :: signed( cold) ,
18251826 hot,
You can’t perform that action at this time.
0 commit comments