NSG feature branch cleanup. (#1422)

This commit is contained in:
Noah McGregor Harper
2021-11-01 16:17:43 -07:00
committed by Stas
parent 3c519f0372
commit c2bfa2a132
8 changed files with 31 additions and 30 deletions

View File

@ -46,8 +46,8 @@ def get_subnet(
def get_subnet_id(resource_group: str, name: str, subnet_name: str) -> Optional[str]:
subnet = get_subnet(resource_group, name, subnet_name)
if subnet:
return cast(str, subnet.id)
if subnet and isinstance(subnet.id, str):
return subnet.id
else:
return None