aboutsummaryrefslogtreecommitdiffstats
path: root/bot/seasons/halloween/hacktoberstats.py
diff options
context:
space:
mode:
Diffstat (limited to 'bot/seasons/halloween/hacktoberstats.py')
-rw-r--r--bot/seasons/halloween/hacktoberstats.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/bot/seasons/halloween/hacktoberstats.py b/bot/seasons/halloween/hacktoberstats.py
index 5687a5c7..20797037 100644
--- a/bot/seasons/halloween/hacktoberstats.py
+++ b/bot/seasons/halloween/hacktoberstats.py
@@ -10,6 +10,8 @@ import aiohttp
import discord
from discord.ext import commands
+from bot.utils.persist import make_persistent
+
log = logging.getLogger(__name__)
CURRENT_YEAR = datetime.now().year # Used to construct GH API query
@@ -19,9 +21,9 @@ PRS_FOR_SHIRT = 4 # Minimum number of PRs before a shirt is awarded
class HacktoberStats(commands.Cog):
"""Hacktoberfest statistics Cog."""
- def __init__(self, bot):
+ def __init__(self, bot: commands.Bot):
self.bot = bot
- self.link_json = Path("bot/resources/github_links.json")
+ self.link_json = make_persistent(Path("bot", "resources", "halloween", "github_links.json"))
self.linked_accounts = self.load_linked_users()
@commands.group(name="hacktoberstats", aliases=("hackstats",), invoke_without_command=True)