Skip to content

Commit 3818f9b

Browse files
authored
fix: keep the oldest classifications (#574)
1 parent 0954c38 commit 3818f9b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

ami/main/models.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1658,7 +1658,7 @@ def find_duplicates(self, project_id: int | None = None) -> models.QuerySet:
16581658
)
16591659

16601660
# Keep only the oldest classifications
1661-
return self.filter(id__in=[item["min_id"] for item in unique_oldest])
1661+
return self.exclude(id__in=[item["min_id"] for item in unique_oldest])
16621662

16631663

16641664
class ClassificationManager(models.Manager.from_queryset(ClassificationQuerySet)):

0 commit comments

Comments
 (0)