From 94a801241dd6dfd0fca560ea35774ecb6a6cd3d4 Mon Sep 17 00:00:00 2001 From: Ernesto Rico Schmidt <ernesto@helsinki.at> Date: Thu, 16 May 2024 16:53:34 -0400 Subject: [PATCH] style: remove superfluous comments --- program/services.py | 11 ----------- 1 file changed, 11 deletions(-) diff --git a/program/services.py b/program/services.py index 166624bd..690ef5f9 100644 --- a/program/services.py +++ b/program/services.py @@ -632,18 +632,11 @@ def generate_conflicts(timeslots: list[TimeSlot]) -> Conflicts: projected = [] solutions = {} - # Cycle each timeslot for timeslot in timeslots: - # Contains collisions collisions = [] - - # Contains possible solutions solution_choices = set() - - # Get collisions for each timeslot colliding_timeslots = list(get_colliding_timeslots(timeslot).order_by("start")) - # Add the projected timeslot projected_entry = { "hash": timeslot.hash, "start": str(timeslot.start), @@ -651,7 +644,6 @@ def generate_conflicts(timeslots: list[TimeSlot]) -> Conflicts: } for existing in colliding_timeslots: - # Add the collision collision = { "timeslot_id": existing.id, "start": str(existing.start), @@ -663,7 +655,6 @@ def generate_conflicts(timeslots: list[TimeSlot]) -> Conflicts: "memo": existing.memo, } - # Get note try: note = Note.objects.get(timeslot=existing.id) collision["note_id"] = note.pk @@ -672,8 +663,6 @@ def generate_conflicts(timeslots: list[TimeSlot]) -> Conflicts: collisions.append(collision) - """Determine acceptable solutions""" - if len(colliding_timeslots) > 1: # If there is more than one collision: Only these two are supported at the moment solution_choices.add("theirs") -- GitLab