Skip to content

Commit

Permalink
remove DiffSuppressFunc from availability_zones
Browse files Browse the repository at this point in the history
  • Loading branch information
bendrucker committed Apr 23, 2020
1 parent 88d6bb1 commit 4cd65db
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 16 deletions.
10 changes: 0 additions & 10 deletions aws/diff_suppress_funcs.go
Expand Up @@ -97,16 +97,6 @@ func suppressOpenIdURL(k, old, new string, d *schema.ResourceData) bool {
return oldUrl.String() == newUrl.String()
}

func suppressAutoscalingGroupAvailabilityZoneDiffs(k, old, new string, d *schema.ResourceData) bool {
// If VPC zone identifiers are provided then there is no need to explicitly
// specify availability zones.
if _, ok := d.GetOk("vpc_zone_identifier"); ok {
return true
}

return false
}

func suppressCloudFormationTemplateBodyDiffs(k, old, new string, d *schema.ResourceData) bool {
normalizedOld, err := normalizeCloudFormationTemplate(old)

Expand Down
11 changes: 5 additions & 6 deletions aws/resource_aws_autoscaling_group.go
Expand Up @@ -253,12 +253,11 @@ func resourceAwsAutoscalingGroup() *schema.Resource {
},

"availability_zones": {
Type: schema.TypeSet,
Optional: true,
Computed: true,
Elem: &schema.Schema{Type: schema.TypeString},
Set: schema.HashString,
DiffSuppressFunc: suppressAutoscalingGroupAvailabilityZoneDiffs,
Type: schema.TypeSet,
Optional: true,
Computed: true,
Elem: &schema.Schema{Type: schema.TypeString},
Set: schema.HashString,
},

"placement_group": {
Expand Down

0 comments on commit 4cd65db

Please sign in to comment.