Taking in changes from other projects
[doneit] / src / cache_backend.py
index c9968ff..0e4afcb 100644 (file)
@@ -152,11 +152,12 @@ class LazyCacheBackend(object):
                self._invalidate_metaprojects_tasks()
 
        def _invalidate_projects_tasks(self, projId):
-               del self._items[projId]
+               if projId in self._items:
+                       del self._items[projId]
 
        def _invalidate_metaprojects_tasks(self):
-               for projId in self._get_metalists():
-                       self._invalidate_projects_tasks(projId)
+               for proj in self._get_metalists():
+                       self._invalidate_projects_tasks(proj["id"])
 
        def _get_metalists(self):
                return (