Merge pull request #94435 from Hilderin/fix-removing-folder-with-files

Fix removing a folder that contains a file is not removed from the FileSystem Dock
This commit is contained in:
Rémi Verschelde 2024-07-17 11:44:42 +02:00
commit ee9f20b457
No known key found for this signature in database
GPG Key ID: C3336907360768E1

View File

@ -1594,7 +1594,10 @@ bool EditorFileSystem::_find_file(const String &p_file, EditorFileSystemDirector
}
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);
efsd->name = path[i];