mirror of
https://github.com/paradigmxyz/reth.git
synced 2026-04-30 03:01:58 -04:00
perf(rpc): avoid redundant next_env_attributes call in simulate_v1 (#23064)
This commit is contained in:
@@ -127,9 +127,11 @@ pub trait EthCall: EstimateCall + Call + LoadPendingBlock + LoadBlock + FullEthA
|
||||
.into());
|
||||
}
|
||||
|
||||
let attributes = this.next_env_attributes(&parent)?;
|
||||
|
||||
let mut evm_env = this
|
||||
.evm_config()
|
||||
.next_evm_env(&parent, &this.next_env_attributes(&parent)?)
|
||||
.next_evm_env(&parent, &attributes)
|
||||
.map_err(RethError::other)
|
||||
.map_err(Self::Error::from_eth_err)?;
|
||||
|
||||
@@ -205,7 +207,7 @@ pub trait EthCall: EstimateCall + Call + LoadPendingBlock + LoadBlock + FullEthA
|
||||
|
||||
let ctx = this
|
||||
.evm_config()
|
||||
.context_for_next_block(&parent, this.next_env_attributes(&parent)?)
|
||||
.context_for_next_block(&parent, attributes)
|
||||
.map_err(RethError::other)
|
||||
.map_err(Self::Error::from_eth_err)?;
|
||||
let map_err = |e: EthApiError| -> Self::Error {
|
||||
|
||||
Reference in New Issue
Block a user