Replace size() == 0 with is_empty().

This commit is contained in:
Yufeng Ying
2025-03-20 00:07:31 +08:00
parent c7ea8614d7
commit 4f4031a675
147 changed files with 300 additions and 300 deletions

View File

@@ -475,7 +475,7 @@ void SceneDebugger::remove_from_cache(const String &p_filename, Node *p_node) {
HashMap<String, HashSet<Node *>>::Iterator E = edit_cache.find(p_filename);
if (E) {
E->value.erase(p_node);
if (E->value.size() == 0) {
if (E->value.is_empty()) {
edit_cache.remove(E);
}
}
@@ -1178,7 +1178,7 @@ void LiveEditor::_restore_node_func(ObjectID p_id, const NodePath &p_at, int p_a
EN->value.remove(FN);
if (EN->value.size() == 0) {
if (EN->value.is_empty()) {
live_edit_remove_list.remove(EN);
}