From b21c9f894fe4ac27f1c04216f669fccb1f2c7946 Mon Sep 17 00:00:00 2001 From: Sven Heidemann Date: Fri, 3 Nov 2023 14:54:25 +0100 Subject: [PATCH] Fixed sale count for steam offers --- bot/src/modules/special_offers/steam_offer_watcher.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/bot/src/modules/special_offers/steam_offer_watcher.py b/bot/src/modules/special_offers/steam_offer_watcher.py index 66e183ed..65d6f1e9 100644 --- a/bot/src/modules/special_offers/steam_offer_watcher.py +++ b/bot/src/modules/special_offers/steam_offer_watcher.py @@ -113,6 +113,8 @@ class SteamOfferWatcher(TaskABC): # todo: let admins change the value self._logger.debug(__name__, f"Get special offers from 0 to {sale_count}") for i in range(0, sale_count, 100): + if i > sale_count: + break new_offers.extend(self._get_games_from_page(i, 100)) self._logger.debug(__name__, f"Got {new_offers.count()} offers")