aboutsummaryrefslogtreecommitdiffstats
path: root/bot/exts/fun/game.py
diff options
context:
space:
mode:
Diffstat (limited to 'bot/exts/fun/game.py')
-rw-r--r--bot/exts/fun/game.py4
1 files changed, 1 insertions, 3 deletions
diff --git a/bot/exts/fun/game.py b/bot/exts/fun/game.py
index 56e6314f..4ed2e93e 100644
--- a/bot/exts/fun/game.py
+++ b/bot/exts/fun/game.py
@@ -185,9 +185,7 @@ class Games(Cog):
self.genres: dict[str, int] = {}
self.headers = BASE_HEADERS
- self.bot.loop.create_task(self.renew_access_token())
-
- async def renew_access_token(self) -> None:
+ async def cog_load(self) -> None:
"""Refeshes V4 access token a number of seconds before expiry. See `ACCESS_TOKEN_RENEWAL_WINDOW`."""
while True:
async with self.http_session.post(OAUTH_URL, params=OAUTH_PARAMS) as resp: