From 571a691e0eebae59a5f46494a697fe58ac4a11f1 Mon Sep 17 00:00:00 2001 From: Dniel97 Date: Tue, 28 Mar 2023 18:54:27 +0200 Subject: [PATCH] chuni: added `use_login_bonus` check to UserLoginBonusApi --- titles/chuni/base.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/titles/chuni/base.py b/titles/chuni/base.py index 95c35e8..d41d415 100644 --- a/titles/chuni/base.py +++ b/titles/chuni/base.py @@ -396,7 +396,8 @@ class ChuniBase: def handle_get_user_login_bonus_api_request(self, data: Dict) -> Dict: user_id = data["userId"] user_login_bonus = self.data.item.get_all_login_bonus(user_id, self.version) - if user_login_bonus is None: + # ignore the loginBonus request if its disabled in config + if user_login_bonus is None or not self.game_cfg.mods.use_login_bonus: return {"userId": user_id, "length": 0, "userLoginBonusList": []} user_login_list = []