From 2f7ce452334c2e6363e5d7e2d7b2dea7521dde76 Mon Sep 17 00:00:00 2001 From: j <0x006A@0x2620.org> Date: Mon, 7 Oct 2013 09:19:15 +0000 Subject: [PATCH] config['filter'] is gone --- pandora/annotation/tasks.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/pandora/annotation/tasks.py b/pandora/annotation/tasks.py index 9508927b..1e80800e 100644 --- a/pandora/annotation/tasks.py +++ b/pandora/annotation/tasks.py @@ -82,7 +82,7 @@ def add_annotations(data): value=a['value']) annotation.save() #update facets if needed - if filter(lambda f: f['id'] == layer_id, settings.CONFIG['filters']): + if filter(lambda f: f['id'] == layer_id and f.get('filter'), settings.CONFIG['itemKeys']): item.update_layer_facet(layer_id) Item.objects.filter(id=item.id).update(modified=annotation.modified) annotation.item.modified = annotation.modified @@ -99,7 +99,7 @@ def update_item(id): #cleanup orphaned clips Clip.objects.filter(item__id=a.item.id, annotations__id=None).delete() #update facets if needed - if filter(lambda f: f['id'] == a.layer, settings.CONFIG['filters']): + if filter(lambda f: f['id'] == a.layer and f.get('filter'), settings.CONFIG['itemKeys']): a.item.update_layer_facet(a.layer) Item.objects.filter(id=a.item.id).update(modified=a.modified) a.item.modified = a.modified