Skip to content

Commit

Permalink
Fix parsing of from and to fields for deposits
Browse files Browse the repository at this point in the history
  • Loading branch information
intoverflow committed Nov 21, 2023
1 parent b541602 commit 151b4e8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions lib/src/optimism/deposits.rs
Original file line number Diff line number Diff line change
Expand Up @@ -103,10 +103,10 @@ fn to_deposit_transaction(
log_index: usize,
log: &Log,
) -> anyhow::Result<Transaction<OptimismTxEssence>> {
let from = U160::try_from_be_slice(log.topics[1].as_slice())
let from = U160::try_from_be_slice(&log.topics[1][12..])
.context("invalid from")?
.into();
let to = U160::try_from_be_slice(log.topics[2].as_slice())
let to = U160::try_from_be_slice(&log.topics[2][12..])
.context("invalid to")?
.into();

Expand Down

0 comments on commit 151b4e8

Please sign in to comment.