I was testing the cleanup of files by creating a resource and deleting it, and I noticed that the content is never moved into the trash because the draft files remain there:
nsmoodle20=> select id, component, filearea, filename from mdl_files where contenthash = '82d8b776feed71754344544602107247ece6794e';
id | component | filearea | filename
--------- -------- +----------
51 | user | draft | test1.txt
55 | user | draft | test2.txt
There is a comment in the file_storage::cron function that this is still left to do.
//TODO: find out all stale draft areas (older than 1 day) and purge them
// those are identified by time stamp of the /. root dir
I couldn't see an issue in the tracker, so here is one for you, just as a reminder!