Skip to content

Commit

Permalink
chore: Replaced assert by ensure
Browse files Browse the repository at this point in the history
  • Loading branch information
vbar committed Nov 1, 2023
1 parent f6e754f commit dc25c41
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion node/bft/src/primary.rs
Original file line number Diff line number Diff line change
Expand Up @@ -431,7 +431,7 @@ impl<N: Network> Primary<N> {
return Ok(());
}
// Ditto if the batch had already been proposed.
assert!(round > 0);
ensure!(round > 0, "Round 0 cannot have transaction batches");
if *lock_guard == round {
warn!("Primary is safely skipping a batch proposal - round {round} already proposed");
return Ok(());
Expand Down

0 comments on commit dc25c41

Please sign in to comment.