From 19815109632a8bb409de345d4e1103ae8e0cecb2 Mon Sep 17 00:00:00 2001 From: algizn97 Date: Wed, 1 Oct 2025 15:50:13 +0500 Subject: [PATCH] Fixed check tp sl price --- app/bybit/open_positions.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/bybit/open_positions.py b/app/bybit/open_positions.py index 3fd118d..7ee90e3 100644 --- a/app/bybit/open_positions.py +++ b/app/bybit/open_positions.py @@ -382,9 +382,9 @@ async def open_positions( take_profit_price = max(take_profit_price, 0) stop_loss_price = max(stop_loss_price, 0) - if take_profit_price < price_symbol: + if safe_float(take_profit_price) < safe_float(price_symbol): take_profit_price = None - if stop_loss_price > price_symbol: + if safe_float(stop_loss_price) > safe_float(price_symbol): stop_loss_price = None # Place order