Skip to content
Snippets Groups Projects
Commit 7c99b113 authored by Jonathan Weth's avatar Jonathan Weth :keyboard:
Browse files

Apply suggestion to aleksis/apps/chronos/model_extensions.py

parent 4cabda9e
No related branches found
No related tags found
1 merge request!31Biscuit merge. Closes #53.
......@@ -7,7 +7,7 @@ from .models import Lesson, LessonPeriod
def is_teacher(self):
""" Check if the user has lessons as a teacher """
return Lesson.objects.filter(teachers=self).exists()
return self.lesson_periods_as_teacher.exists()
@Person.property
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment