Skip to content

Commit

Permalink
tmp
Browse files Browse the repository at this point in the history
  • Loading branch information
jakedipity committed Dec 23, 2022
1 parent 49abd34 commit 98e0cbb
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 15 deletions.
8 changes: 0 additions & 8 deletions logdna/request_types.go
Original file line number Diff line number Diff line change
Expand Up @@ -85,8 +85,6 @@ type childOrgPutRequest struct {
Retention int `json:"retention"`
}

type childOrgDeleteRequest struct{}

func (view *viewRequest) CreateRequestBody(d *schema.ResourceData) diag.Diagnostics {
// This function pulls from the schema in preparation to JSON marshal
var diags diag.Diagnostics
Expand Down Expand Up @@ -200,12 +198,6 @@ func (childOrg *childOrgPutRequest) CreateRequestBody(d *schema.ResourceData) di
return diags
}

func (childOrg *childOrgDeleteRequest) CreateRequestBody(d *schema.ResourceData) diag.Diagnostics {
var diags diag.Diagnostics

return diags
}

func aggregateAllChannelsFromSchema(
d *schema.ResourceData,
diags *diag.Diagnostics,
Expand Down
8 changes: 1 addition & 7 deletions logdna/resource_child_organization.go
Original file line number Diff line number Diff line change
Expand Up @@ -119,20 +119,14 @@ func resourceChildOrgUpdate(ctx context.Context, d *schema.ResourceData, m inter
}

func resourceChildOrgDelete(ctx context.Context, d *schema.ResourceData, m interface{}) diag.Diagnostics {
var diags diag.Diagnostics
pc := m.(*providerConfig)
childOrgID := d.Id()

childOrg := childOrgDeleteRequest{}
if diags = childOrg.CreateRequestBody(d); diags.HasError() {
return diags
}

req := newRequestConfig(
pc,
"DELETE",
fmt.Sprintf("/v1/enterprise/account/%s", childOrgID),
childOrg,
nil,
)

body, err := req.MakeRequest()
Expand Down

0 comments on commit 98e0cbb

Please sign in to comment.