provider/openstack: gophercloud migration: Only set 'gateway_ip' to "" if 'no_gateway' == true.

This commit is contained in:
Gavin Williams 2016-10-07 17:19:53 +01:00 committed by Joe Topjian
parent 8405a9f118
commit 28466f50a5
1 changed files with 3 additions and 3 deletions

View File

@ -245,9 +245,9 @@ func resourceNetworkingSubnetV2Update(d *schema.ResourceData, meta interface{})
}
if d.HasChange("no_gateway") {
noGateway := d.Get("no_gateway").(bool)
if noGateway {
updateOpts.GatewayIP = nil
if d.Get("no_gateway").(bool) {
gatewayIP := ""
updateOpts.GatewayIP = &gatewayIP
}
}