Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

resource/codedeploy_deployment_group: Use flattenStringSet helper #16288

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions aws/resource_aws_codedeploy_deployment_group.go
Original file line number Diff line number Diff line change
Expand Up @@ -1167,7 +1167,7 @@ func triggerConfigsToMap(list []*codedeploy.TriggerConfig) []map[string]interfac
result := make([]map[string]interface{}, 0, len(list))
for _, tc := range list {
item := make(map[string]interface{})
item["trigger_events"] = schema.NewSet(schema.HashString, flattenStringList(tc.TriggerEvents))
item["trigger_events"] = flattenStringSet(tc.TriggerEvents)
item["trigger_name"] = *tc.TriggerName
item["trigger_target_arn"] = *tc.TriggerTargetArn
result = append(result, item)
Expand All @@ -1185,7 +1185,7 @@ func autoRollbackConfigToMap(config *codedeploy.AutoRollbackConfiguration) []map
if config != nil && (*config.Enabled || len(config.Events) > 0) {
item := make(map[string]interface{})
item["enabled"] = *config.Enabled
item["events"] = schema.NewSet(schema.HashString, flattenStringList(config.Events))
item["events"] = flattenStringSet(config.Events)
result = append(result, item)
}

Expand All @@ -1206,7 +1206,7 @@ func alarmConfigToMap(config *codedeploy.AlarmConfiguration) []map[string]interf
}

item := make(map[string]interface{})
item["alarms"] = schema.NewSet(schema.HashString, flattenStringList(names))
item["alarms"] = flattenStringSet(names)
item["enabled"] = *config.Enabled
item["ignore_poll_alarm_failure"] = *config.IgnorePollAlarmFailure

Expand Down Expand Up @@ -1297,7 +1297,7 @@ func flattenCodeDeployTrafficRoute(trafficRoute *codedeploy.TrafficRoute) []inte
}

m := map[string]interface{}{
"listener_arns": schema.NewSet(schema.HashString, flattenStringList(trafficRoute.ListenerArns)),
"listener_arns": flattenStringSet(trafficRoute.ListenerArns),
}

return []interface{}{m}
Expand Down