From c1150f927a4e423c249ad36a93ecbfdb2806eb60 Mon Sep 17 00:00:00 2001 From: Nawaz Haider Date: Thu, 15 Jan 2026 16:32:02 +0600 Subject: [PATCH] Fix trading logic conditions for order placement based on market trend direction --- main.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main.py b/main.py index 96b1dd3..b608364 100644 --- a/main.py +++ b/main.py @@ -83,7 +83,7 @@ def main(): if get_trades_count() < MAX_TRADES: trading_side = book.last_signal - if (trading_side == SIGNALES.UP) and up_trend: + if (trading_side == SIGNALES.UP) and not up_trend: order_ids = place_anchor_and_hedge( up_token, down_token, @@ -98,7 +98,7 @@ def main(): ) time.sleep(MIN_DELAY_BETWEEN_TRADES_SECONDS) - elif (trading_side == SIGNALES.DOWN) and not up_trend: + elif (trading_side == SIGNALES.DOWN) and up_trend: order_ids = place_anchor_and_hedge( up_token, down_token,