Dont' attempt to remove drive if ID is "None" (#49423)

pull/48873/head
Marcin 6 years ago committed by Zim Kalinowski
parent 7fcd55f3ec
commit 8a7d19788c

@ -1431,6 +1431,7 @@ class AzureRMVirtualMachine(AzureRMModuleBase):
data_disks = vm.storage_profile.data_disks
for data_disk in data_disks:
if data_disk is not None:
if(data_disk.vhd):
vhd_uris.append(data_disk.vhd.uri)
elif(data_disk.managed_disk):

Loading…
Cancel
Save