rewrite: Minor bugfixes.

This commit is contained in:
2023-05-23 18:16:12 +03:00
parent f0dd540876
commit 0e1fb84bcb
6 changed files with 13 additions and 10 deletions

View File

@@ -569,6 +569,10 @@ class WeeklyMonthlyUI(StatsUI):
if page_type.stat is StatType.VOICE:
model = self.data.VoiceSessionStats
elif page_type.stat is StatType.TEXT:
model = self.bot.get_cog('TextTrackerCog').data.TextSessions
else:
model = self.data.VoiceSessionStats
first_result = await model.table.select_one_where(**data_key).order_by('start_time')
if first_result is None: