Skip to content

Commit

Permalink
Clippy
Browse files Browse the repository at this point in the history
  • Loading branch information
mbjorkqvist committed Sep 26, 2024
1 parent 410ae4f commit e3a5aaa
Showing 1 changed file with 3 additions and 4 deletions.
7 changes: 3 additions & 4 deletions rs/rosetta-api/icrc1/tests/golden_state_upgrade_downgrade.rs
Original file line number Diff line number Diff line change
Expand Up @@ -145,10 +145,9 @@ impl LedgerState {
burns_without_spender: Option<BurnsWithoutSpender<Account>>,
previous_ledger_state: Option<LedgerState>,
) -> Self {
let num_blocks_to_fetch = match &previous_ledger_state {
None => None,
Some(previous_ledger_state) => Some(previous_ledger_state.num_blocks),
};
let num_blocks_to_fetch = previous_ledger_state
.as_ref()
.map(|previous_ledger_state| previous_ledger_state.num_blocks);

let mut ledger_state = LedgerState::new(burns_without_spender);
// Only fetch the blocks that were present when the previous state was generated. This is
Expand Down

0 comments on commit e3a5aaa

Please sign in to comment.