Commit 2684895f authored by Erase's avatar Erase
Browse files

Changes the deletion time

parent b64db6b5
......@@ -11,7 +11,7 @@
$conf = TL_ROOT . '/../../c/'.$_GET['c'];
//~ Update file date (file is deleted if is not updated every 3 weeks)
//~ Update file date (file is deleted if is not updated every 30 days)
touch($conf);
//~ Open conf
......
......@@ -97,8 +97,8 @@
while (false !== ($file = readdir($handle))){
//~ Check the file we're doing is actually a file
if (is_file($path.$file) && $file !== 'index.php' && $file !== '.gitignore'){
//~ Check if the file is older than 3 week old
if (filemtime($path.$file) < (time() - (3 * 7 * 24 * 60 * 60))){ //~ 3 weeks
//~ Check if the file is older than 30 days old
if (filemtime($path.$file) < (time() - (30 * 24 * 60 * 60))){ //~ 3 days
//~ Do the deletion
unlink($path.$file);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment