Fix if the route table changed to none (#49533)

pull/49711/head
Yuwei Zhou 6 years ago committed by Zim Kalinowski
parent c0d95a73ff
commit 5a59748e6c

@ -241,6 +241,7 @@ class AzureRMSubnet(AzureRMModuleBase):
if self.security_group:
nsg = self.parse_nsg()
route_table = dict()
if self.route_table:
route_table = self.parse_resource_to_dict(self.route_table)
self.route_table = format_resource_id(val=route_table['name'],
@ -276,7 +277,7 @@ class AzureRMSubnet(AzureRMModuleBase):
if self.route_table != results['route_table'].get('id'):
changed = True
results['route_table']['id'] = self.route_table
self.log("CHANGED: subnet {0} route_table to {1}".format(self.name, route_table['name']))
self.log("CHANGED: subnet {0} route_table to {1}".format(self.name, route_table.get('name')))
if self.service_endpoints:
oldd = {}

Loading…
Cancel
Save