Skip to content

Commit 04bda77

Browse files
committed
fix allocation group delete
1 parent 05698a8 commit 04bda77

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

internal/provider/allocation_group_resource.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -228,18 +228,18 @@ func (r *allocationGroupResource) Update(ctx context.Context, req resource.Updat
228228
func (r *allocationGroupResource) Delete(ctx context.Context, req resource.DeleteRequest, resp *resource.DeleteResponse) {
229229
log.Print(" allocation group Delete")
230230
// Retrieve values from state
231-
var state allocationResourceModel
231+
var state allocationGroupResourceModel
232232
diags := req.State.Get(ctx, &state)
233233
resp.Diagnostics.Append(diags...)
234234
if resp.Diagnostics.HasError() {
235235
return
236236
}
237237

238238
// Delete existing allocation
239-
err := r.client.DeleteAllocation(state.Id.ValueString())
239+
err := r.client.DeleteAllocationGroup(state.Id.ValueString())
240240
if err != nil {
241241
resp.Diagnostics.AddError(
242-
"Error Deleting DoiT Allocation",
242+
"Error Deleting DoiT Allocation group",
243243
"Could not delete allocation, unexpected error: "+err.Error(),
244244
)
245245
return

0 commit comments

Comments
 (0)