Skip to content

Commit c6121ee

Browse files
committed
use is ok and
1 parent d9add2e commit c6121ee

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

pallets/subtensor/src/staking/set_children.rs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,7 @@ impl<T: Config> Pallet<T> {
108108
children.is_empty()
109109
|| Self::get_total_stake_for_hotkey(&hotkey) >= StakeThreshold::<T>::get()
110110
|| SubnetOwnerHotkey::<T>::try_get(netuid)
111-
.and_then(|owner_hotkey| Ok(owner_hotkey.eq(&hotkey)))
112-
.unwrap_or(false),
111+
.is_ok_and(|owner_hotkey| owner_hotkey.eq(&hotkey)),
113112
Error::<T>::NotEnoughStakeToSetChildkeys
114113
);
115114

0 commit comments

Comments
 (0)