Fix _uuids_cache reset in BugDir._clear_bugs
authorW. Trevor King <wking@drexel.edu>
Thu, 21 Jan 2010 17:48:07 +0000 (12:48 -0500)
committerW. Trevor King <wking@drexel.edu>
Thu, 21 Jan 2010 17:48:07 +0000 (12:48 -0500)
libbe/bugdir.py

index 006f0b82ba4917db72bf7fa00e39cf830d6db6a1..83897164303d15f78db4efe6860ea3964dac7859 100644 (file)
@@ -248,7 +248,8 @@ class BugDir (list, settings_object.SavedSettingsObject):
     def _clear_bugs(self):
         while len(self) > 0:
             self.pop()
-        del(self._uuids_cache)
+        if hasattr(self, '_uuids_cache'):
+            del(self._uuids_cache)
         self._bug_map_gen()
 
     def _load_bug(self, uuid):