Skip to content
This repository has been archived by the owner on Oct 31, 2024. It is now read-only.

Commit

Permalink
fix: optimize
Browse files Browse the repository at this point in the history
  • Loading branch information
Marko Atanasievski committed Mar 4, 2024
1 parent ee35451 commit 99cfa96
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions crates/topos-sequencer-subnet-runtime/src/certification.rs
Original file line number Diff line number Diff line change
Expand Up @@ -132,10 +132,11 @@ impl Certification {

// Remove processed blocks
for processed_block_number in processed_blocks {
let mut front_block_number = None;
if let Some(front) = self.finalized_blocks.front() {
front_block_number = Some(front.number);
}
let mut front_block_number = if let Some(front) = self.finalized_blocks.front() {
Some(front.number)
} else {
None
};

if front_block_number.is_some() {
if Some(processed_block_number) == front_block_number {
Expand Down

0 comments on commit 99cfa96

Please sign in to comment.