Skip to content

Commit

Permalink
program: remove ununused code, fix from audit
Browse files Browse the repository at this point in the history
Signed-off-by: microwavedcola1 <[email protected]>
  • Loading branch information
microwavedcola1 committed Aug 19, 2024
1 parent 7863062 commit 3052d2e
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 5 deletions.
1 change: 1 addition & 0 deletions programs/mango-v4/src/instructions/token_liq_bankruptcy.rs
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ pub fn token_liq_bankruptcy(

// find the insurance bank token index
let insurance_mint = ctx.accounts.insurance_vault.mint;
require_keys_eq!(insurance_mint, group.insurance_mint);
let insurance_token_index = health_ais
.iter()
.find_map(|ai| {
Expand Down
5 changes: 0 additions & 5 deletions programs/mango-v4/src/state/group.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,6 @@ pub type TokenIndex = u16;
/// incorrect assumption.
pub const QUOTE_TOKEN_INDEX: TokenIndex = 0;

/// The token index used for the insurance fund.
///
/// We should eventually generalize insurance funds.
pub const INSURANCE_TOKEN_INDEX: TokenIndex = 0;

/// The token index used for settling perp markets.
///
/// We should eventually generalize to make the whole perp quote (and settle) token
Expand Down

0 comments on commit 3052d2e

Please sign in to comment.