summaryrefslogtreecommitdiffstats
path: root/system/application/controllers/file.php
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xssn.at>2010-03-05 14:29:29 +0100
committerFlorian Pritz <bluewind@xssn.at>2010-03-05 14:29:29 +0100
commit793e6bcd0825f98571c3767c8e702da5d34a11a4 (patch)
tree7b0711bf624cc3d84b819be550595c7b70e2ad84 /system/application/controllers/file.php
parent6ffac5d6ecd013988961e0ee914bf086519b52d5 (diff)
file/cron: fix error if file doesn't exists
Signed-off-by: Florian Pritz <bluewind@xssn.at>
Diffstat (limited to 'system/application/controllers/file.php')
-rw-r--r--system/application/controllers/file.php2
1 files changed, 1 insertions, 1 deletions
diff --git a/system/application/controllers/file.php b/system/application/controllers/file.php
index 37658ea19..1d4a369f7 100644
--- a/system/application/controllers/file.php
+++ b/system/application/controllers/file.php
@@ -206,7 +206,7 @@ class File extends Controller {
foreach($query->result_array() as $row) {
$file = $this->file_mod->file($row['hash']);
- if(filemtime($file) < $oldest_time) {
+ if(file_exists($file) && filemtime($file) < $oldest_time) {
unlink($file);
$this->db->query('DELETE FROM files WHERE hash = ?', array($row['hash']));
} else {