diff --git a/aleksis/apps/alsijil/util/predicates.py b/aleksis/apps/alsijil/util/predicates.py index f0abe866b2b1b422ac59b0ce71eb279cfcc759ec..1eb8a8e8ff7913bf957902ae8329cf70ea490300 100644 --- a/aleksis/apps/alsijil/util/predicates.py +++ b/aleksis/apps/alsijil/util/predicates.py @@ -16,7 +16,7 @@ def is_lesson_teacher(user: User, obj: LessonPeriod) -> bool: Checks whether the person linked to the user is a teacher in the lesson linked to the given LessonPeriod. """ - return user.person in obj.lesson.teachers + return user.person in obj.lesson.teachers.all() @predicate