fix bug that causes a slice with no nodes to have an in incorrect rspec
authorTony Mack <tmack@paris.CS.Princeton.EDU>
Tue, 6 Mar 2012 16:36:21 +0000 (11:36 -0500)
committerTony Mack <tmack@paris.CS.Princeton.EDU>
Tue, 6 Mar 2012 16:36:21 +0000 (11:36 -0500)
sfa/plc/plaggregate.py

index 55e6291..b0c78d1 100644 (file)
@@ -138,7 +138,7 @@ class PlAggregate:
     def get_nodes_and_links(self, slice=None,slivers=[], options={}):
         # if we are dealing with a slice that has no node just return 
         # and empty list    
-        if slice is not None and not slice['node_ids']:
+        if not slice or  not slice['node_ids']:
             return ([],[])
 
         filter = {}