diff --git a/src/gui b/src/gui index 0153ee25..24e94d10 160000 --- a/src/gui +++ b/src/gui @@ -1 +1 @@ -Subproject commit 0153ee258be36fe77b81d88765e65be38406ecab +Subproject commit 24e94d10e2ef2e34a6feb2bc8f9eca268260f512 diff --git a/src/modules/statistics/data.py b/src/modules/statistics/data.py index 30448701..76ba4cf6 100644 --- a/src/modules/statistics/data.py +++ b/src/modules/statistics/data.py @@ -126,7 +126,7 @@ class StatsData(Registry): @classmethod @log_wrap(action='study_times_between') - async def study_times_between(cls, guildid: int, userid: int, *points) -> list[int]: + async def study_times_between(cls, guildid: Optional[int], userid: int, *points) -> list[int]: if len(points) < 2: raise ValueError('Not enough block points given!') @@ -165,8 +165,8 @@ class StatsData(Registry): return (await cursor.fetchone()[0]) or 0 @classmethod - @log_wrap(action='study_times_between') - async def study_times_since(cls, guildid: int, userid: int, *starts) -> int: + @log_wrap(action='study_times_since') + async def study_times_since(cls, guildid: Optional[int], userid: int, *starts) -> int: if len(starts) < 1: raise ValueError('No starting points given!') diff --git a/src/modules/statistics/graphics/profile.py b/src/modules/statistics/graphics/profile.py index 3a413d4a..759a974b 100644 --- a/src/modules/statistics/graphics/profile.py +++ b/src/modules/statistics/graphics/profile.py @@ -76,7 +76,7 @@ async def get_profile_card(bot: LionBot, userid: int, guildid: int): else: next_rank = None - achievements = (0, 1) + achievements = (0, 1, 2, 3) card = ProfileCard( user=username, diff --git a/src/modules/statistics/graphics/stats.py b/src/modules/statistics/graphics/stats.py index b10607d8..ffa19bb0 100644 --- a/src/modules/statistics/graphics/stats.py +++ b/src/modules/statistics/graphics/stats.py @@ -34,7 +34,7 @@ async def get_stats_card(bot: LionBot, userid: int, guildid: int, mode: CardMode # Extract the study times for each period if mode in (CardMode.STUDY, CardMode.VOICE): model = data.VoiceSessionStats - refkey = (guildid, userid) + refkey = (guildid or None, userid) ref_since = model.study_times_since ref_between = model.study_times_between elif mode is CardMode.TEXT: