Skip to content

Commit

Permalink
cleanup debug code
Browse files Browse the repository at this point in the history
  • Loading branch information
nbaztec committed Oct 11, 2024
1 parent b4ece57 commit 393dd6d
Showing 1 changed file with 1 addition and 8 deletions.
9 changes: 1 addition & 8 deletions crates/zksync/core/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -198,11 +198,7 @@ pub async fn estimate_gas<P: Provider<T, AnyNetwork>, T: Transport + Clone>(
provider.get_gas_price().await?
};
let data = tx.input.clone().into_input().unwrap_or_default();
for d in &factory_deps {
println!("{}", hex::encode(&d));
}
let custom_data = Eip712Meta::new().factory_deps(factory_deps);
let custom_data_min = Eip712Meta::new();

let mut deploy_request = Eip712TransactionRequest::new()
.r#type(EIP712_TX_TYPE)
Expand All @@ -211,14 +207,11 @@ pub async fn estimate_gas<P: Provider<T, AnyNetwork>, T: Transport + Clone>(
.nonce(nonce)
.gas_price(gas_price)
.data(data.to_ethers())
.custom_data(custom_data_min);
.custom_data(custom_data);
if let Some(from) = tx.from {
deploy_request = deploy_request.from(from.to_h160())
}

println!("{}", serde_json::to_string_pretty(&deploy_request).unwrap());
deploy_request = deploy_request.custom_data(custom_data);

let gas_price = provider.get_gas_price().await.unwrap();
let fee: Fee = provider
.raw_request("zks_estimateFee".into(), [deploy_request.clone()])
Expand Down

0 comments on commit 393dd6d

Please sign in to comment.