### Godot version

v4.0.beta17.mono.official [c40020513]

### System information

Window 11, Forward+, GTX 1060

### Issue description

Adding two theme variations in a row result to a  crash.

https://user-images.githubusercontent.com/93253123/217037249-1ce1d56d-beb6-4435-83ad-9f8a07fe0e96.mp4



### Steps to reproduce

1. Create a project.
2. Create a theme.
3. Double click to go in the theme editor.
4. Click on manage items buttons.
5. In the add type field type a name to add a type.
6. type another name to add a second type.
7. Crash.

### Minimal reproduction project

[ThemeVariationCrash.zip](https://github.com/godotengine/godot/files/10665863/ThemeVariationCrash.zip)

void _resource_selected(const String &p_path, Ref<Resource> p_resource);
	void _property_selected(const String &p_path, int p_focusable);
	void _object_id_selected(const String &p_path, ObjectID p_id);
	void _node_removed(Node *p_node);
	HashMap<StringName, int> per_array_page;
	void _page_change_request(int p_new_page, const StringName &p_array_prefix);
	void _changed_callback();
	void _edit_request_change(Object *p_object, const String &p_prop);
	void _filter_changed(const String &p_text);
	void _parse_added_editors(VBoxContainer *current_vbox, EditorInspectorSection *p_section, Ref<EditorInspectorPlugin> ped);
	void _vscroll_changed(double);
	void _feature_profile_changed();
	bool _is_property_disabled_by_feature_profile(const StringName &p_property);
	void _update_inspector_bg();
	ConfirmationDialog *add_meta_dialog = nullptr;
	LineEdit *add_meta_name = nullptr;
	OptionButton *add_meta_type = nullptr;
	Label *add_meta_error = nullptr;
	void _add_meta_confirm();
	void _show_add_meta_dialog();
	void _check_meta_name(const String &p_name);
protected:
	static void _bind_methods();
	void _notification(int p_what);
public:
	static void add_inspector_plugin(const Ref<EditorInspectorPlugin> &p_plugin);
	static void remove_inspector_plugin(const Ref<EditorInspectorPlugin> &p_plugin);
	static void cleanup_plugins();
	static Button *create_inspector_action_button(const String &p_text);
	static EditorProperty *instantiate_property_editor(Object *p_object, const Variant::Type p_type, const String &p_path, const PropertyHint p_hint, const String &p_hint_text, const uint32_t p_usage, const bool p_wide = false);