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

make sure find resource return valid path before clean the cache #1745

Merged
merged 1 commit into from
Nov 16, 2017

Conversation

yanwsh
Copy link
Contributor

@yanwsh yanwsh commented Nov 10, 2017

Hello, i currently encounter a issue which are super danger if user accidentally remove assets folder. and run 'gpm install' on their machine.
The findResource method will return false and glob($path . '/*') will return the whole directory of user's root disk, which will remove everything on your current disk.

Here is a screen shot show how it looks like.
cache_php_-_holiday-gift-guide_-____htdocs_holiday-gift-guide_

I know it's my fault, but it shouldn't broken my computer.

make sure find resource return valid path.
@rhukster rhukster merged commit 72f3a01 into getgrav:develop Nov 16, 2017
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.

3 participants