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

Delete temporary directories with broken symlinks. #39

Merged
merged 1 commit into from
Jun 8, 2020

Conversation

matejd
Copy link
Contributor

@matejd matejd commented Jun 6, 2020

This change handles a case where a temporary directory could not be deleted because it contained a symlink to a non-existing file.

The issue is that file_exists() returns false for broken symlinks. This in turn means that method deleteDirectory() will skip the broken symlink and then fail at rmdir() because directory is not actually empty.

@freekmurze freekmurze merged commit dcdb003 into spatie:master Jun 8, 2020
@freekmurze
Copy link
Member

Thanks!

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

Successfully merging this pull request may close these issues.

2 participants