# Plugin Developpement Error: Assertion failed: (Index \>= 0) & (Index \< ArrayNum) \[File:D:\\Epic Games\\UE\_5.4\\Engine\\Source\\Runtime\\Core\\Public\\Containers\\Array.h\] \[Line: 758\]

**URL:** <https://forums.unrealengine.com/t/plugin-developpement-error-assertion-failed-index-0-index-arraynum-file-epic-games-ue-5-4-engine-source-runtime-core-public-containers-array-h-line-758/2188645>\
**Category:** Debugging, Optimization, & Profiling\
**Tags:** unreal-engine, bug-report, question\
**Created:** [December 9, 2024, 2:34pm UTC](https://forums.unrealengine.com/t/plugin-developpement-error-assertion-failed-index-0-index-arraynum-file-epic-games-ue-5-4-engine-source-runtime-core-public-containers-array-h-line-758/2188645 "2024-12-09T14:34:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![AlexkinG21](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@AlexkinG21](https://forums.unrealengine.com/u/AlexkinG21)\
**Post date:** [December 9, 2024, 2:34pm UTC](https://forums.unrealengine.com/t/plugin-developpement-error-assertion-failed-index-0-index-arraynum-file-epic-games-ue-5-4-engine-source-runtime-core-public-containers-array-h-line-758/2188645/1 "2024-12-09T14:34:24Z")

</div>

Hi, So I’m currently developping a plugin for unreal right now. In my plugin, I can item to a list made with slate. The issue is when I’m removing more then 3 items (sometimes 2) in a row, I get this error : Error: Assertion failed: (Index \>= 0) & (Index \< ArrayNum) [File:D:\Epic Games\UE\_5.4\Engine\Source\Runtime\Core\Public\Containers\Array.h] [Line: 758]

I saw people had the issue while using UE for game dev and especially with skeleton mesh but here, I don’t have anything like that and the crash occurs when using the plugin.

To remove an item, here’s what I do :

```auto
//Create new preset object
	FPreset* Preset = new FPreset();
	//Add preset to list
	int Index = PresetList->Add(*Preset);
	//Add slot in configuration form
	PropertyConfigFormContainer->AddSlot()
	.Padding(0, 0.0f, 0.0f, 5.0f)
	[
		SNew(SPresetConfigurationWidget)
		.PresetData(Preset)
		.Controls(ControlList)
		.OnRemove_Lambda([this, Index](TSharedRef<SWidget> FormWidget) {
			// Remove item in preset list
			PresetList->RemoveAt(Index);
			// Remove widget
			PropertyConfigFormContainer->RemoveSlot(FormWidget);
		})
	];

```

I don’t get why this only occurs after deleting a few in a row. Also, if a remove an item and close the panel them reopen it to remove more items, this works perfectly fines.

Any help would be appreciated, thank you in advance !
