Skip to content

Commit

Permalink
Fix TryInto<L1BatchMetadata> for StorageL1Batch
Browse files Browse the repository at this point in the history
  • Loading branch information
perekopskiy committed Feb 17, 2024
1 parent 8f55cae commit e0330f2
Showing 1 changed file with 3 additions and 9 deletions.
12 changes: 3 additions & 9 deletions core/lib/dal/src/models/storage_block.rs
Original file line number Diff line number Diff line change
Expand Up @@ -234,15 +234,9 @@ impl TryInto<L1BatchMetadata> for StorageL1Batch {
.merkle_root_hash
.ok_or(StorageL1BatchConvertError::Incomplete)?,
),
initial_writes_compressed: self
.compressed_initial_writes
.ok_or(StorageL1BatchConvertError::Incomplete)?,
repeated_writes_compressed: self
.compressed_repeated_writes
.ok_or(StorageL1BatchConvertError::Incomplete)?,
l2_l1_messages_compressed: self
.l2_l1_compressed_messages
.ok_or(StorageL1BatchConvertError::Incomplete)?,
initial_writes_compressed: self.compressed_initial_writes.unwrap_or_default(),
repeated_writes_compressed: self.compressed_repeated_writes.unwrap_or_default(),
l2_l1_messages_compressed: self.l2_l1_compressed_messages.unwrap_or_default(),
l2_l1_merkle_root: H256::from_slice(
&self
.l2_l1_merkle_root
Expand Down

0 comments on commit e0330f2

Please sign in to comment.