Add function to delete unmanaged files recursively
drewish - February 12, 2009 - 18:16
| Project: | Drupal |
| Version: | 7.x-dev |
| Component: | file system |
| Category: | feature request |
| Priority: | normal |
| Assigned: | drewish |
| Status: | closed |
| Issue tags: | D7FileAPIWishlist, ImageCacheInCore |
Description
This functionality is forked off of #371374: Add ImageCache UI Core and based on code that's been in ImageCache for quite a while.
| Attachment | Size | Status | Test result | Operations |
|---|---|---|---|---|
| file_delete_recursive.patch | 6.2 KB | Idle | Failed: Failed to run tests. | View details | Re-test |

#1
The last submitted patch failed testing.
#2
fixing a bug in the tests and a missed replacement of simpletest_clean_temporary_directory() with file_unmanaged_delete_recursive().
#3
Straightforward. Only very minor issues:
+ // Catch all for other types of files like sockets....I had to read twice to understand.
++
Doubled blank lines in file.test.
If the tests will pass and those very minor issues are fixed, this is RTBC.
#4
thanks sun, fixed those issues.
#5
We can also provide some return value. Slightly simplified that comment.
#6
sun, i intentionally did not return a value since you'd really need to check the whole way down the tree.
#7
Removed the return value.
But also fixed some coding-style issues. Yikes!
#8
#9
#10
how about this so we avoid checking is_file is_link over and over?
#11
okay, now with return value. and better docs.
#12
what a beautiful bikeshed we've built!
[ignore this... wrong patch]
#13
with an extra the now.
#14
#15
Excellent work, folks. :) Committed to HEAD.
#16
Automatically closed -- issue fixed for 2 weeks with no activity.