Skip to content

Commit

Permalink
chore: simplify if
Browse files Browse the repository at this point in the history
  • Loading branch information
Evalir committed May 12, 2023
1 parent 2d0ed7c commit d72a935
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion evm/src/executor/inspector/cheatcodes/expect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,7 @@ pub fn handle_expect_emit(state: &mut Cheatcodes, log: RawLog, address: &Address
// First, we can return early if all events have been matched.
// This allows a contract to arbitrarily emit more events than expected (additive behavior),
// as long as all the previous events were matched in the order they were expected to be.
if !state.expected_emits.iter().any(|expected| !expected.found) {
if state.expected_emits.iter().all(|expected| expected.found) {
return
}

Expand Down

0 comments on commit d72a935

Please sign in to comment.