Skip to content

Commit 9f09d94

Browse files
author
Samuel Dare
committed
chore: clippy
1 parent fae9db0 commit 9f09d94

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

pallets/subtensor/src/root.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -577,8 +577,8 @@ impl<T: Config> Pallet<T> {
577577
}
578578

579579
// --- 15. Update the registration counters for both the block and interval.
580-
RegistrationsThisInterval::<T>::mutate(root_netuid, |val| *val += 1);
581-
RegistrationsThisBlock::<T>::mutate(root_netuid, |val| *val += 1);
580+
RegistrationsThisInterval::<T>::mutate(root_netuid, |val| val.saturating_inc());
581+
RegistrationsThisBlock::<T>::mutate(root_netuid, |val| val.saturating_inc());
582582

583583
// --- 16. Log and announce the successful registration.
584584
log::info!(

0 commit comments

Comments
 (0)