update from RIFT as of 696b75d2fe9fb046261b08c616f1bcf6c0b54a9b second try
[osm/SO.git] / rwcal / plugins / vala / rwcal_aws / rift / rwcal / aws / delete_vm.py
index 05d744b..8c1ce04 100644 (file)
@@ -41,7 +41,7 @@ def cleanup_vm(drv,argument):
         logger.info("Deleting network interface with id %s",port_id)
         port = drv.get_network_interface(port_id)
         if port:
-            if port.association and 'AssociationId' in port.association:
+            if port.association_attribute  and 'AssociationId' in port.association_attribute:
                 drv.disassociate_public_ip_from_network_interface(NetworkInterfaceId=port.id)
             drv.delete_network_interface(port.id)
         else: