### Tested versions

v4.2.stable.official [46dc27791]

### System information

Windows 11- Godot v4.2.stable.official [46dc27791] - Vulkan (Forward+)

### Issue description

![image](https://github.com/godotengine/godot/assets/46812028/f57e3f30-b3c4-4a83-8793-64a58bd18220)


### Steps to reproduce

Create a new project and select a color in modulate

### Minimal reproduction project (MRP)

N/A
List<Color>::Element *e = presets.find(p_color);
	if (e) {
		presets.erase(e);
		preset_cache.erase(preset_cache.find(p_color));
		
		for (int i = 1; i < preset_container->get_child_count(); i++) {
			ColorPresetButton *current_btn = Object::cast_to<ColorPresetButton>(preset_container->get_child(i));
			if (current_btn && p_color == current_btn->get_preset_color()) {
				current_btn->queue_free();
				break;
			}
		}
#ifdef TOOLS_ENABLED
		if (editor_settings) {
			PackedColorArray arr_to_save = get_presets();
			editor_settings->call(SNAME("set_project_metadata"), "color_picker", "presets", arr_to_save);
		}
#endif
	}
}
void ColorPicker::erase_recent_preset(const Color &p_color) {