fix: expose call method so a consumer can use it (#3680)

Co-authored-by: Matthias Seitz <matthias.seitz@outlook.de>
This commit is contained in:
Josh Stevens
2023-07-09 15:14:36 +01:00
committed by GitHub
parent 1330fc11df
commit f116040e63

View File

@@ -38,18 +38,14 @@ where
Network: NetworkInfo + Send + Sync + 'static,
{
/// Estimate gas needed for execution of the `request` at the [BlockId].
pub(crate) async fn estimate_gas_at(
&self,
request: CallRequest,
at: BlockId,
) -> EthResult<U256> {
pub async fn estimate_gas_at(&self, request: CallRequest, at: BlockId) -> EthResult<U256> {
let (cfg, block_env, at) = self.evm_env_at(at).await?;
let state = self.state_at(at)?;
self.estimate_gas_with(cfg, block_env, request, state)
}
/// Executes the call request (`eth_call`) and returns the output
pub(crate) async fn call(
pub async fn call(
&self,
request: CallRequest,
block_number: Option<BlockId>,