Skip to content

Commit

Permalink
cargo clippy --fix
Browse files Browse the repository at this point in the history
  • Loading branch information
awnion committed Jan 31, 2024
1 parent 2191498 commit 2d4c9e5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/transaction_executor.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1439,12 +1439,13 @@ fn outmsg_action_handler(
_ => (),
}
let mut acc_balance_copy = ExtraCurrencyCollection::default();
match acc_balance.other.iterate_with_keys(|key: u32, b| -> Result<bool> {
let predicate = |key: u32, b: tvm_block::VarUInteger32| -> Result<bool> {
if !b.is_zero() {
acc_balance_copy.set(&key, &b)?;
}
Ok(true)
}) {
};
match acc_balance.other.iterate_with_keys(predicate) {
Ok(false) | Err(_) => {
log::warn!(target: "executor", "Cannot reduce account extra balance");
return Err(skip.map(|_| RESULT_CODE_INVALID_BALANCE).unwrap_or_default());
Expand Down

0 comments on commit 2d4c9e5

Please sign in to comment.