From 77899683f652035caa3d21045f17768716f7ce2c Mon Sep 17 00:00:00 2001 From: Siddhu Warrier Date: Wed, 13 Nov 2024 15:24:15 +1100 Subject: [PATCH] fix(cisco-live-2024): remove tenant name validation (#150) The tenant name validation is not working when we pass the name parameter as a var --- provider/internal/msp/msp_tenant/resource.go | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/provider/internal/msp/msp_tenant/resource.go b/provider/internal/msp/msp_tenant/resource.go index 6ce903a..11d61b4 100644 --- a/provider/internal/msp/msp_tenant/resource.go +++ b/provider/internal/msp/msp_tenant/resource.go @@ -6,11 +6,9 @@ import ( cdoClient "github.com/CiscoDevnet/terraform-provider-cdo/go-client" "github.com/CiscoDevnet/terraform-provider-cdo/go-client/msp/tenants" "github.com/CiscoDevnet/terraform-provider-cdo/internal/util" - "github.com/CiscoDevnet/terraform-provider-cdo/validators" "github.com/hashicorp/terraform-plugin-framework/resource" "github.com/hashicorp/terraform-plugin-framework/resource/schema" "github.com/hashicorp/terraform-plugin-framework/resource/schema/planmodifier" - "github.com/hashicorp/terraform-plugin-framework/schema/validator" "github.com/hashicorp/terraform-plugin-framework/types" "github.com/hashicorp/terraform-plugin-log/tflog" ) @@ -35,10 +33,7 @@ func (*TenantResource) Schema(ctx context.Context, request resource.SchemaReques }, "name": schema.StringAttribute{ MarkdownDescription: "Name of the tenant", - Validators: []validator.String{ - validators.NewCdoTenantValidator(), - }, - Required: true, + Required: true, PlanModifiers: []planmodifier.String{ PreventUpdatePlanModifier{}, // Prevent updates to name },