From 03ae594478536e5d89724d342076417808285f12 Mon Sep 17 00:00:00 2001 From: magiodev <31893902+magiodev@users.noreply.github.com> Date: Tue, 30 Jul 2024 15:39:01 +0200 Subject: [PATCH] remove unnecessary early returns --- .../osmosis/contracts/cl-vault/src/helpers/getters.rs | 4 ---- 1 file changed, 4 deletions(-) diff --git a/smart-contracts/osmosis/contracts/cl-vault/src/helpers/getters.rs b/smart-contracts/osmosis/contracts/cl-vault/src/helpers/getters.rs index 4f4603f2b..05947e6c9 100644 --- a/smart-contracts/osmosis/contracts/cl-vault/src/helpers/getters.rs +++ b/smart-contracts/osmosis/contracts/cl-vault/src/helpers/getters.rs @@ -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