Do not shutdown non-resources
authorEnrico Zini <enrico@enricozini.org>
Sun, 14 Jun 2009 03:32:16 +0000 (11:32 +0800)
committerEnrico Zini <enrico@enricozini.org>
Sun, 14 Jun 2009 03:32:16 +0000 (11:32 +0800)
zavai/registry.py

index cc2a1c0c5c3f0c86729604b47d88efd04a41c5a6..1694196bae6eaa8ddcf2aff731ea1e1f985f7461 100644 (file)
@@ -92,7 +92,8 @@ class Registry(object):
 
         After shutting down, all objects cannot be used anymore"""
         for o in self.objects.itervalues():
-            o.shutdown()
+            if isinstance(o, Resource):
+                o.shutdown()
         self.objects.clear()
 
 class Resource(object):