diff --git a/resources/environments/converter_gcp.go b/resources/environments/converter_gcp.go index 986aca34..b119e836 100644 --- a/resources/environments/converter_gcp.go +++ b/resources/environments/converter_gcp.go @@ -141,12 +141,8 @@ func toGcpEnvironmentResource(ctx context.Context, env *environmentsmodels.Envir model.StatusReason = types.StringValue(env.StatusReason) tflog.Info(ctx, "about to convert tags.") if env.Tags != nil { - merged := env.Tags.Defaults - for k, v := range env.Tags.UserDefined { - merged[k] = v - } var tagDiags diag.Diagnostics - tagMap, tagDiags := types.MapValueFrom(ctx, types.StringType, merged) + tagMap, tagDiags := types.MapValueFrom(ctx, types.StringType, env.Tags.UserDefined) diags.Append(tagDiags...) model.Tags = tagMap } diff --git a/resources/environments/resource_aws_environment.go b/resources/environments/resource_aws_environment.go index 2c7abfc2..f3780be4 100644 --- a/resources/environments/resource_aws_environment.go +++ b/resources/environments/resource_aws_environment.go @@ -203,12 +203,8 @@ func toAwsEnvironmentResource(ctx context.Context, env *environmentsmodels.Envir model.Status = types.StringPointerValue(env.Status) model.StatusReason = types.StringValue(env.StatusReason) if env.Tags != nil { - merged := env.Tags.Defaults - for k, v := range env.Tags.UserDefined { - merged[k] = v - } var tagDiags diag.Diagnostics - tagMap, tagDiags := types.MapValueFrom(ctx, types.StringType, merged) + tagMap, tagDiags := types.MapValueFrom(ctx, types.StringType, env.Tags.UserDefined) diags.Append(tagDiags...) model.Tags = tagMap } diff --git a/resources/environments/resource_azure_environment.go b/resources/environments/resource_azure_environment.go index e6408c30..37514db1 100644 --- a/resources/environments/resource_azure_environment.go +++ b/resources/environments/resource_azure_environment.go @@ -210,11 +210,7 @@ func toAzureEnvironmentResource(ctx context.Context, env *environmentsmodels.Env model.Status = types.StringPointerValue(env.Status) model.StatusReason = types.StringValue(env.StatusReason) if env.Tags != nil { - merged := env.Tags.Defaults - for k, v := range env.Tags.UserDefined { - merged[k] = v - } - tagMap, tagDiags := types.MapValueFrom(ctx, types.StringType, merged) + tagMap, tagDiags := types.MapValueFrom(ctx, types.StringType, env.Tags.UserDefined) diags.Append(tagDiags...) model.Tags = tagMap }