From 10550fe2286c2c61c4ea2f529fd745cade207904 Mon Sep 17 00:00:00 2001 From: Maximilian Krambach Date: Sat, 19 Jan 2019 15:07:51 +0100 Subject: [PATCH] fix server set marked for users that already have spoken --- openslides/agenda/views.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/openslides/agenda/views.py b/openslides/agenda/views.py index 308b1decd..fe4504ac6 100644 --- a/openslides/agenda/views.py +++ b/openslides/agenda/views.py @@ -159,9 +159,10 @@ class ItemViewSet(ListModelMixin, RetrieveModelMixin, UpdateModelMixin, GenericV if not isinstance(marked, bool): raise ValidationError({"detail": "Marked has to be a bool."}) - queryset = Speaker.objects.filter(item=item, user=user) + queryset = Speaker.objects.filter(item=item, user=user, begin_time=None) try: - # We assume that there aren't multiple entries because this + # We assume that there aren't multiple entries for speakers that + # did not yet begin to speak, because this # is forbidden by the Manager's add method. We assume that # there is only one speaker instance or none. speaker = queryset.get()