diff --git a/cloudconnexa/data_source_connector.go b/cloudconnexa/data_source_connector.go index 2d822da..ffb4ab4 100644 --- a/cloudconnexa/data_source_connector.go +++ b/cloudconnexa/data_source_connector.go @@ -2,9 +2,6 @@ package cloudconnexa import ( "context" - "strconv" - "time" - "github.com/hashicorp/terraform-plugin-sdk/v2/diag" "github.com/hashicorp/terraform-plugin-sdk/v2/helper/schema" "github.com/openvpn/cloudconnexa-go-client/v2/cloudconnexa" @@ -71,7 +68,7 @@ func dataSourceConnectorRead(ctx context.Context, d *schema.ResourceData, m inte if err != nil { return append(diags, diag.FromErr(err)...) } - d.Set("connector_id", connector.Id) + d.SetId(connector.Id) d.Set("name", connector.Name) d.Set("description", connector.Description) d.Set("network_item_id", connector.NetworkItemId) @@ -84,6 +81,5 @@ func dataSourceConnectorRead(ctx context.Context, d *schema.ResourceData, m inte return append(diags, diag.FromErr(err)...) } d.Set("profile", profile) - d.SetId(strconv.FormatInt(time.Now().Unix(), 10)) return diags }