Check for empty zone string

This commit is contained in:
Hemant Kumar
2020-04-29 10:46:15 -04:00
parent 850da22c02
commit 9d4329f62c
2 changed files with 9 additions and 7 deletions

View File

@@ -77,7 +77,7 @@ func (p *Provider) CreatePD(zone string) (string, error) {
}
// do not use blank zone definition
if len(zone) > 0 && zone != "0" {
if len(zone) > 0 {
volumeOptions.AvailabilityZone = zone
}
return p.azureCloud.CreateManagedDisk(volumeOptions)