From bd68bed639c2135c986572d9ce170493b8822231 Mon Sep 17 00:00:00 2001 From: "Konstantin Shperling (Toksi)" <79082640+Toksi86@users.noreply.github.com> Date: Tue, 8 Oct 2024 19:17:33 +0500 Subject: [PATCH] Fix team assignment bug where other players were removed from the team when assigned (#569) Co-authored-by: Konstantin Raikhert --- adaptive_hockey_federation/main/forms.py | 3 --- 1 file changed, 3 deletions(-) diff --git a/adaptive_hockey_federation/main/forms.py b/adaptive_hockey_federation/main/forms.py index f4baeedb..9d55d803 100644 --- a/adaptive_hockey_federation/main/forms.py +++ b/adaptive_hockey_federation/main/forms.py @@ -205,9 +205,6 @@ def save(self, commit=True): instance = super().save(commit=False) if commit: instance.save() - instance.team.through.objects.filter( - team__in=self.cleaned_data["team"], - ).delete() instance.team.set(self.cleaned_data["team"]) return instance