### Godot version

 v4.0.beta11.official.91713ced8

### System information

macOS 12.6.1 Monterey, Apple M1 Pro

### Issue description

After reopening scenes with Sprite2D and trying to edit the region of the sprite again the Godot app crashed.

### Steps to reproduce

1. Open scene node_2d in the project files
2. Go to Sprite2D and click on edit region, pop up should show
3. Close the popup and close the scene with X on the tab
4. Reopen the scene, go to Sprite2D and click on Edit region
5. Godot should crash

### Minimal reproduction project

[region_crash.zip](https://github.com/godotengine/godot/files/10400566/region_crash.zip)

edit_draw->add_child(zoom_hb);
	zoom_hb->set_begin(Point2(5, 5));
	zoom_out = memnew(Button);
	zoom_out->set_flat(true);
	zoom_out->set_tooltip_text(TTR("Zoom Out"));
	zoom_out->connect("pressed", callable_mp(this, &TextureRegionEditor::_zoom_out));
	zoom_hb->add_child(zoom_out);
	zoom_reset = memnew(Button);
	zoom_reset->set_flat(true);
	zoom_reset->set_tooltip_text(TTR("Zoom Reset"));
	zoom_reset->connect("pressed", callable_mp(this, &TextureRegionEditor::_zoom_reset));
	zoom_hb->add_child(zoom_reset);
	zoom_in = memnew(Button);
	zoom_in->set_flat(true);
	zoom_in->set_tooltip_text(TTR("Zoom In"));
	zoom_in->connect("pressed", callable_mp(this, &TextureRegionEditor::_zoom_in));
	zoom_hb->add_child(zoom_in);
	vscroll = memnew(VScrollBar);
	vscroll->set_step(0.001);
	edit_draw->add_child(vscroll);
	vscroll->connect("value_changed", callable_mp(this, &TextureRegionEditor::_scroll_changed));
	hscroll = memnew(HScrollBar);
	hscroll->set_step(0.001);
	edit_draw->add_child(hscroll);
	hscroll->connect("value_changed", callable_mp(this, &TextureRegionEditor::_scroll_changed));
	updating_scroll = false;
	autoslice_is_dirty = true;
	set_title(TTR("Region Editor"));
}
bool EditorInspectorPluginTextureRegion::can_handle(Object *p_object) {