From 3a9fd875b2908b3ef23cc4e097ad6c9a0000f7fe Mon Sep 17 00:00:00 2001 From: Tanner Collin Date: Sun, 29 Mar 2020 02:30:34 +0000 Subject: [PATCH] Filter out cancelled meetings and cleanups --- apiserver/apiserver/api/utils_stats.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/apiserver/apiserver/api/utils_stats.py b/apiserver/apiserver/api/utils_stats.py index 9267017..f951f80 100644 --- a/apiserver/apiserver/api/utils_stats.py +++ b/apiserver/apiserver/api/utils_stats.py @@ -25,8 +25,8 @@ def changed_card(): def calc_next_events(): sessions = models.Session.objects - member_meeting = sessions.filter(course=317, datetime__gte=now()).first() - monthly_clean = sessions.filter(course=273, datetime__gte=now()).first() + member_meeting = sessions.filter(is_cancelled=False, course=317, datetime__gte=now()).first() + monthly_clean = sessions.filter(is_cancelled=False, course=273, datetime__gte=now()).first() if member_meeting: cache.set('next_meeting', member_meeting.datetime)