added destroy_instances()
[plcapi.git] / PLC / Methods / DeleteSliceFromNodes.py
index 1a82ad1..b89c681 100644 (file)
@@ -47,6 +47,10 @@ class DeleteSliceFromNodes(Method):
 
         # Get specified nodes
         nodes = Nodes(self.api, node_id_or_hostname_list)
+
+        # destroy compute instances 
+        slice.destroy_instances(nodes)
+
         for node in nodes:
             if slice['peer_id'] is not None and node['peer_id'] is not None:
                 raise PLCPermissionDenied, "Not allowed to remove peer slice from peer node"