diff --git a/.changelog/3351.txt b/.changelog/3351.txt new file mode 100644 index 0000000000..135e94dbaf --- /dev/null +++ b/.changelog/3351.txt @@ -0,0 +1,3 @@ +```release-note:bug +resource/cloudflare_waiting_room_event: fix panic when trying to import a resource +``` diff --git a/internal/sdkv2provider/resource_cloudflare_waiting_room_event.go b/internal/sdkv2provider/resource_cloudflare_waiting_room_event.go index 69e2104550..168d0ef9c3 100644 --- a/internal/sdkv2provider/resource_cloudflare_waiting_room_event.go +++ b/internal/sdkv2provider/resource_cloudflare_waiting_room_event.go @@ -193,7 +193,7 @@ func resourceCloudflareWaitingRoomEventImport(ctx context.Context, d *schema.Res if len(idAttr) == 3 { zoneID = idAttr[0] waitingRoomID = idAttr[1] - waitingRoomEventID = idAttr[3] + waitingRoomEventID = idAttr[2] } else { return nil, fmt.Errorf("invalid id (\"%s\") specified, should be in format \"zoneID/waitingRoomID/eventID\" for import", d.Id()) }