Skip to content

Commit

Permalink
chore(perf): remove unneeded to_vec conversion (#6990)
Browse files Browse the repository at this point in the history
* chore: remove unneeded to_vec conversion

* clippy
  • Loading branch information
Evalir authored Feb 1, 2024
1 parent b73df7c commit f5af8d6
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion crates/anvil/src/eth/backend/genesis.rs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ impl GenesisConfig {
/// Converts a [`GenesisAccount`] to an [`AccountInfo`]
fn genesis_to_account_info(&self, acc: &GenesisAccount) -> AccountInfo {
let GenesisAccount { code, balance, nonce, .. } = acc.clone();
let code = code.map(|code| Bytecode::new_raw(code.to_vec().into()));
let code = code.map(Bytecode::new_raw);
AccountInfo {
balance,
nonce: nonce.unwrap_or_default(),
Expand Down

0 comments on commit f5af8d6

Please sign in to comment.