Skip to content

Commit

Permalink
remove unnecessary early returns
Browse files Browse the repository at this point in the history
  • Loading branch information
magiodev committed Jul 30, 2024
1 parent 0870652 commit 03ae594
Showing 1 changed file with 0 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,6 @@ pub fn get_position_balance(
// Handle cases where either asset amount is zero
if asset0_amount.is_zero() && asset1_amount.is_zero() {
return Ok((0.0, 0.0));
} else if asset0_amount.is_zero() {
return Ok((0.0, 1.0));
} else if asset1_amount.is_zero() {
return Ok((1.0, 0.0));
}

// Get the total amount of the vault's position in asset0 denom
Expand Down

0 comments on commit 03ae594

Please sign in to comment.