Skip to content

Commit

Permalink
Hqndling the location being nil for legacy resources
Browse files Browse the repository at this point in the history
Fixes #678
  • Loading branch information
tombuildsstuff committed Mar 15, 2018
1 parent 913bcd7 commit 0ca7dd6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion azurerm/resource_arm_sql_elasticpool.go
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,9 @@ func resourceArmSqlElasticPoolRead(d *schema.ResourceData, meta interface{}) err

d.Set("name", resp.Name)
d.Set("resource_group_name", resGroup)
d.Set("location", azureRMNormalizeLocation(*resp.Location))
if location := resp.Location; location != nil {
d.Set("location", azureRMNormalizeLocation(*location))
}
d.Set("server_name", serverName)

if elasticPool := resp.ElasticPoolProperties; elasticPool != nil {
Expand Down

0 comments on commit 0ca7dd6

Please sign in to comment.