summaryrefslogtreecommitdiffstats
path: root/system/libraries/Cache/drivers/Cache_file.php
diff options
context:
space:
mode:
authorAndrey Andreev <narf@devilix.net>2014-07-31 12:32:41 +0200
committerAndrey Andreev <narf@devilix.net>2014-07-31 12:32:41 +0200
commit5f0799aa859914cb6ed4428f023b8f46406218c3 (patch)
treedc7d7906c3967f7de32802a1d7d7881c25423605 /system/libraries/Cache/drivers/Cache_file.php
parent466af6c937bb7402cafe4f6c1392df7ccc526953 (diff)
Fix #3161
Diffstat (limited to 'system/libraries/Cache/drivers/Cache_file.php')
-rw-r--r--system/libraries/Cache/drivers/Cache_file.php12
1 files changed, 10 insertions, 2 deletions
diff --git a/system/libraries/Cache/drivers/Cache_file.php b/system/libraries/Cache/drivers/Cache_file.php
index c6aa848fe..aa2e8fa38 100644
--- a/system/libraries/Cache/drivers/Cache_file.php
+++ b/system/libraries/Cache/drivers/Cache_file.php
@@ -125,7 +125,11 @@ class CI_Cache_file extends CI_Driver {
{
$data = $this->_get($id);
- if ($data === FALSE OR ! is_int($data['data']))
+ if ($data === FALSE)
+ {
+ $data = array('data' => 0, 'ttl' => 60);
+ }
+ elseif ( ! is_int($data['data']))
{
return FALSE;
}
@@ -149,7 +153,11 @@ class CI_Cache_file extends CI_Driver {
{
$data = $this->_get($id);
- if ($data === FALSE OR ! is_int($data['data']))
+ if ($data === FALSE)
+ {
+ $data = array('data' => 0, 'ttl' => 60);
+ }
+ elseif ( ! is_int($data['data']))
{
return FALSE;
}