diff --git a/oml/item/models.py b/oml/item/models.py index ef18dd1..3037245 100644 --- a/oml/item/models.py +++ b/oml/item/models.py @@ -322,7 +322,7 @@ class Item(db.Model): def remove_annotations(self): from annotation.models import Annotation - for a in Annotation.query.filter_by(item_id=self.id, user_id=state.user().id): + for a in Annotation.query.filter_by(item_id=self.id, user_id=settings.USER_ID): a.add_record('removeannotation') a.delete()