From eb3d3d8a8d4483b4998fc01ecbfaa5c26fcd0612 Mon Sep 17 00:00:00 2001 From: Sergio Chouhy Date: Mon, 27 Apr 2026 18:48:28 -0300 Subject: [PATCH] simplify insert account logic --- wallet/src/chain_storage.rs | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/wallet/src/chain_storage.rs b/wallet/src/chain_storage.rs index 60756cd8..1f7036de 100644 --- a/wallet/src/chain_storage.rs +++ b/wallet/src/chain_storage.rs @@ -193,16 +193,6 @@ impl WalletChainStore { .entry(account_id) { let entry = entry.get_mut(); - let identifier = entry - .accounts - .iter() - .find_map(|(id, _)| { - (nssa::AccountId::from((&entry.key_chain.nullifier_public_key, *id)) - == account_id) - .then_some(*id) - }) - .unwrap_or(0); - // Update existing entry or insert new one if let Some((_, acc)) = entry.accounts.iter_mut().find(|(id, _)| *id == identifier) { *acc = account; } else {