Skip to content

Commit

Permalink
Fix errors during filtering Nodes in the editor.
Browse files Browse the repository at this point in the history
  • Loading branch information
Relintai committed Feb 8, 2024
1 parent f4118ae commit a5fcaa5
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions editor/scene_tree_editor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -655,8 +655,6 @@ bool SceneTreeEditor::_update_filter(TreeItem *p_parent, bool p_scroll_to_select
}
}
}
} else {
memdelete(p_parent);
}

if (editor_selection) {
Expand All @@ -673,6 +671,11 @@ bool SceneTreeEditor::_update_filter(TreeItem *p_parent, bool p_scroll_to_select
}
}

if (!(keep_for_children || keep)) {
memdelete(p_parent);
return false;
}

return keep || keep_for_children;
}

Expand Down

0 comments on commit a5fcaa5

Please sign in to comment.