aboutsummaryrefslogtreecommitdiff
path: root/views.py
diff options
context:
space:
mode:
authorAlban Gruin2017-09-27 13:48:44 +0200
committerAlban Gruin2017-09-27 13:48:44 +0200
commitba343196f8305dfadf01f8a617b05e6d9723ce13 (patch)
treed54e4bcbe4d934d3ba8efc0ddcad9ba5e272b1f4 /views.py
parentaa7ccf13a8735f162e2ea859ad1d8ebe9f34f657 (diff)
On compare le résultat de la fonction à 0, pas la fonction
Diffstat (limited to 'views.py')
-rw-r--r--views.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/views.py b/views.py
index eb6a7ac..66f0a03 100644
--- a/views.py
+++ b/views.py
@@ -64,7 +64,7 @@ def timetable(request, year_slug, timetable_slug, group_slug, year=None, week=No
group = get_object_or_404(Group, slug=group_slug, timetable=timetable)
courses = Course.objects.get_courses_for_group(group, begin__gte=start, begin__lt=end).annotate(Max("last_update"))
- if courses.count == 0:
+ if courses.count() == 0:
raise Http404
grouped_courses = group_courses(courses)