Remove redundant author validation check in collection_take_start and streamline access control in ExamOrCollectionGenericBase

This commit is contained in:
Ross
2025-09-15 11:34:17 +01:00
parent de8050a8ca
commit 298493a390
2 changed files with 3 additions and 4 deletions
+3
View File
@@ -768,6 +768,9 @@ class ExamOrCollectionGenericBase(models.Model, AuthorMixin):
Raises:
Http404: If user does not have access
"""
if user is not None and self.is_author(user):
return
# If we are limiting by dates check that the current date is within the range
if self.restrict_to_dates:
if self.start_date >= timezone.now() or (