diff --git a/crates/storage/store.rs b/crates/storage/store.rs
index 52ea8bccc19..69fdbd613a9 100644
--- a/crates/storage/store.rs
+++ b/crates/storage/store.rs
@@ -2275,18 +2275,13 @@ impl Store {
let Some(state_trie) = self.state_trie(block_hash)? else {
return Ok(None);
};
- let hashed_address = hash_address_fixed(&address);
-
- let Some(encoded_state) = state_trie.get(hashed_address.as_bytes())? else {
- return Ok(None);
- };
-
- let account_state = AccountState::decode(&encoded_state)?;
- Ok(Some(AccountInfo {
- code_hash: account_state.code_hash,
- balance: account_state.balance,
- nonce: account_state.nonce,
- }))
+ Ok(self
+ .get_account_state_from_trie(&state_trie, address)?
+ .map(|account_state| AccountInfo {
+ code_hash: account_state.code_hash,
+ balance: account_state.balance,
+ nonce: account_state.nonce,
+ }))
}
pub fn get_account_state_by_acc_hash(
@@ -2324,18 +2319,10 @@ impl Store {
block_number: BlockNumber,
address: Address,
) -> Result