1
0
mirror of https://github.com/godotengine/godot.git synced 2025-11-09 12:50:35 +00:00

Fix removing a folder that contains a file is not removed from the FileSystem Dock

This commit is contained in:
Hilderin
2024-07-16 08:40:55 -04:00
parent 97b8ad1af0
commit a1ef54fd3b

View File

@@ -1594,7 +1594,10 @@ bool EditorFileSystem::_find_file(const String &p_file, EditorFileSystemDirector
} }
if (idx == -1) { if (idx == -1) {
//does not exist, create i guess? // Only create a missing directory in memory when it exists on disk.
if (!dir->dir_exists(fs->get_path().path_join(path[i]))) {
return false;
}
EditorFileSystemDirectory *efsd = memnew(EditorFileSystemDirectory); EditorFileSystemDirectory *efsd = memnew(EditorFileSystemDirectory);
efsd->name = path[i]; efsd->name = path[i];