From fb738c25cfd30b223a3fe993420521ebb5208579 Mon Sep 17 00:00:00 2001 From: j Date: Wed, 28 Jun 2017 12:55:01 +0200 Subject: [PATCH] self.id --- pandora/annotation/models.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pandora/annotation/models.py b/pandora/annotation/models.py index 633e791df..08219234d 100644 --- a/pandora/annotation/models.py +++ b/pandora/annotation/models.py @@ -206,7 +206,7 @@ class Annotation(models.Model): # remove undefined matches that only have this annotation for p in a_matches.filter(defined=False).exclude(name=self.value): - if p.annotations.exclude(id=id).count() == 0: + if p.annotations.exclude(id=self.id).count() == 0: p.delete() if layer.get('type') == type and a_matches.count() == 0: a_matches.add(Model.get_or_create(self.value))