mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-06-13 19:51:05 +00:00
Implement iter for doublemap (#5504)
* implement iter for doublemap * fmt * fix tests * fix staking mock * address comment * update doc and constraint for reversible hasher Co-authored-by: Gavin Wood <gavin@parity.io>
This commit is contained in:
@@ -626,7 +626,7 @@ decl_module! {
|
||||
fn remove_recovery(origin) {
|
||||
let who = ensure_signed(origin)?;
|
||||
// Check there are no active recoveries
|
||||
let mut active_recoveries = <ActiveRecoveries<T>>::iter_prefix(&who);
|
||||
let mut active_recoveries = <ActiveRecoveries<T>>::iter_prefix_values(&who);
|
||||
ensure!(active_recoveries.next().is_none(), Error::<T>::StillActive);
|
||||
// Take the recovery configuration for this account.
|
||||
let recovery_config = <Recoverable<T>>::take(&who).ok_or(Error::<T>::NotRecoverable)?;
|
||||
|
||||
Reference in New Issue
Block a user