Skip to content

Commit

Permalink
refactor: commit classes trie concurrently
Browse files Browse the repository at this point in the history
  • Loading branch information
nimrod-starkware committed Jul 17, 2024
1 parent 1d383c5 commit 52b93d4
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -55,11 +55,10 @@ impl FilledForest {
address_to_class_hash: &HashMap<ContractAddress, ClassHash>,
address_to_nonce: &HashMap<ContractAddress, Nonce>,
) -> ForestResult<Self> {
let classes_trie = ClassesTrie::create::<TH>(
let classes_trie_task = ClassesTrie::create::<TH>(
Arc::new(updated_forest.classes_trie),
Arc::new(classes_updates),
)
.await?;
);

let mut contracts_trie_modifications = HashMap::new();
let mut filled_storage_tries = HashMap::new();
Expand Down Expand Up @@ -105,7 +104,7 @@ impl FilledForest {
Ok(Self {
storage_tries: filled_storage_tries,
contracts_trie,
classes_trie,
classes_trie: classes_trie_task.await?,
})
}

Expand Down

0 comments on commit 52b93d4

Please sign in to comment.