MDL-32547 backup: Add setting for backup folder tidy up.

This commit is contained in:
Adrian Greeve
2014-11-28 09:30:03 +08:00
parent 67eb7d7804
commit c35d736a44
4 changed files with 17 additions and 2 deletions
+1 -1
View File
@@ -46,7 +46,7 @@ class file_temp_cleanup_task extends scheduled_task {
$tmpdir = $CFG->tempdir;
// Default to last weeks time.
$time = strtotime('-1 week');
$time = time() - ($CFG->tempdatafoldercleanup * 3600);
$dir = new \RecursiveDirectoryIterator($tmpdir);
// Show all child nodes prior to their parent.