Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

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

Merged

Conversation

Hilderin
Copy link
Contributor

@Hilderin Hilderin commented Jul 16, 2024

The issue is a side-effect from #92303. To be able to manage correctly the removing of scripts with global class names, I added all removed files in scan_actions with the action ACTION_FILE_REMOVE. But in _update_scene_groups or _update_script_documentation the method find_file is called, which calls _find_file. The method _find_file recreates the parent folder of the searched file if it does not exist in filesystem.

I added a check to prevent adding a folder in filesystem that does not exist on the disk.

Copy link
Member

@AThousandShips AThousandShips left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

editor/editor_file_system.cpp Outdated Show resolved Hide resolved
@Hilderin Hilderin force-pushed the fix-removing-folder-with-files branch from c5e6578 to a1ef54f Compare July 16, 2024 12:53
@KoBeWi
Copy link
Member

KoBeWi commented Jul 16, 2024

Might also fix #93097

@Hilderin
Copy link
Contributor Author

Hilderin commented Jul 16, 2024

I confirm, I tested the MRP from #93097 before and after the fix and this PR solves #93097 also.

@akien-mga akien-mga merged commit ee9f20b into godotengine:master Jul 17, 2024
18 checks passed
@akien-mga
Copy link
Member

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants