Skip to content

Commit

Permalink
Workaround upstream issue in creating azureEndpoints in traffic manag…
Browse files Browse the repository at this point in the history
…er (#1546)
  • Loading branch information
phekmat authored and tombuildsstuff committed Jul 12, 2018
1 parent 0a9ceed commit 68df047
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions azurerm/resource_arm_traffic_manager_endpoint.go
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,10 @@ func getArmTrafficManagerEndpointProperties(d *schema.ResourceData) *trafficmana

if resourceId := d.Get("target_resource_id").(string); resourceId != "" {
endpointProps.TargetResourceID = utils.String(resourceId)
//TODO? Workaround for upstream behavior: if the target is blank instead of nil, the REST API will throw a 500 error. Remove if/when no longer necessary
if target == "" {
endpointProps.Target = nil
}
}

if location := d.Get("endpoint_location").(string); location != "" {
Expand Down

0 comments on commit 68df047

Please sign in to comment.