From eb6fc6513c770a38f74f51fc05637504fd1d396d Mon Sep 17 00:00:00 2001 From: Stijn De Clercq Date: Mon, 30 Aug 2021 22:03:31 +0200 Subject: [PATCH] Sync bank interest & daily reminders @ 4 am, as requested by @GyroFalc --- cogs/tasks.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cogs/tasks.py b/cogs/tasks.py index 7f17b2d..8209d19 100644 --- a/cogs/tasks.py +++ b/cogs/tasks.py @@ -35,7 +35,7 @@ class Tasks(commands.Cog): # Don't do it multiple times a day if bot dc's, ... with open("files/lastTasks.json", "r") as fp: lastTasks = json.load(fp) - if int(self.getCurrentHour()) == 0 and int(time.time()) - int(lastTasks["interest"]) > 10000: + if int(self.getCurrentHour()) == 4 and int(time.time()) - int(lastTasks["interest"]) > 10000: users = currency.getAllRows() bitcoinPrice = self.getCurrentBitcoinPrice() for user in users: @@ -188,7 +188,7 @@ class Tasks(commands.Cog): # Don't do it multiple times a day if bot dc's, ... with open("files/lastTasks.json", "r") as fp: lastTasks = json.load(fp) - if int(self.getCurrentHour()) == 7 and int(time.time()) - int(lastTasks["remind"]) > 10000: + if int(self.getCurrentHour()) == 4 and int(time.time()) - int(lastTasks["remind"]) > 10000: reminders = Reminders() weekday = self.getCurrentWeekday()