Skip to content

Commit 5af9888

Browse files
committed
revert rename user_add_network
1 parent 619757f commit 5af9888

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

pallets/subtensor/src/coinbase/root.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -908,7 +908,7 @@ impl<T: Config> Pallet<T> {
908908
/// * 'NotEnoughBalanceToStake': If there isn't enough balance to stake for network registration.
909909
/// * 'BalanceWithdrawalError': If an error occurs during balance withdrawal for network registration.
910910
///
911-
pub fn user_add_network_with_identity(
911+
pub fn user_add_network(
912912
origin: T::RuntimeOrigin,
913913
identity: Option<SubnetIdentityOf>,
914914
) -> dispatch::DispatchResult {

pallets/subtensor/src/macros/dispatches.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -902,7 +902,7 @@ mod dispatches {
902902
.saturating_add(T::DbWeight::get().reads(16))
903903
.saturating_add(T::DbWeight::get().writes(30)), DispatchClass::Operational, Pays::No))]
904904
pub fn register_network(origin: OriginFor<T>) -> DispatchResult {
905-
Self::user_add_network_with_identity(origin, None)
905+
Self::user_add_network(origin, None)
906906
}
907907

908908
/// Facility extrinsic for user to get taken from faucet
@@ -1208,7 +1208,7 @@ mod dispatches {
12081208
origin: OriginFor<T>,
12091209
identity: Option<SubnetIdentityOf>,
12101210
) -> DispatchResult {
1211-
Self::user_add_network_with_identity(origin, identity)
1211+
Self::user_add_network(origin, identity)
12121212
}
12131213
}
12141214
}

pallets/subtensor/tests/root.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1012,15 +1012,15 @@ fn test_user_add_network_with_identity_fields_ok() {
10121012

10131013
SubtensorModule::add_balance_to_coldkey_account(&coldkey_1, balance_1);
10141014

1015-
assert_ok!(SubtensorModule::user_add_network_with_identity(
1015+
assert_ok!(SubtensorModule::user_add_network(
10161016
RuntimeOrigin::signed(coldkey_1),
10171017
Some(identity_value_1.clone())
10181018
));
10191019

10201020
let balance_2 = SubtensorModule::get_network_lock_cost() + 10_000;
10211021
SubtensorModule::add_balance_to_coldkey_account(&coldkey_2, balance_2);
10221022

1023-
assert_ok!(SubtensorModule::user_add_network_with_identity(
1023+
assert_ok!(SubtensorModule::user_add_network(
10241024
RuntimeOrigin::signed(coldkey_2),
10251025
Some(identity_value_2.clone())
10261026
));

0 commit comments

Comments
 (0)