Skip to content

Commit e4e9905

Browse files
committed
fix: Omit to when tx.to is None
1 parent dc4f3f8 commit e4e9905

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/services/gas/handlers/polygon_zkevm.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ use serde_json;
1818
fn build_zkevm_transaction_params(tx: &EvmTransactionData) -> serde_json::Value {
1919
serde_json::json!({
2020
"from": tx.from,
21-
"to": tx.to.as_ref().unwrap_or(&"0x".to_string()),
21+
"to": tx.to.clone(),
2222
"value": format!("0x{:x}", tx.value),
2323
"data": tx.data.as_ref().map(|d| {
2424
if d.starts_with("0x") { d.clone() } else { format!("0x{}", d) }

0 commit comments

Comments
 (0)