diff options
author | Ben Edmunds <ben.edmunds@gmail.com> | 2011-08-20 21:11:21 +0200 |
---|---|---|
committer | Ben Edmunds <ben.edmunds@gmail.com> | 2011-08-20 21:11:21 +0200 |
commit | 80f4c34d1c5a51d82ae3dd898a12466e01790f10 (patch) | |
tree | 3cf37ebecda35eef1183fa3ed27e709ddf6f73f9 /system/libraries/Cache/drivers | |
parent | d56be70257696d0bbf2dcc880888d8dc17cba21c (diff) |
Resolved issue 160. Removed unneeded array copy.
Diffstat (limited to 'system/libraries/Cache/drivers')
-rw-r--r-- | system/libraries/Cache/drivers/Cache_file.php | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/system/libraries/Cache/drivers/Cache_file.php b/system/libraries/Cache/drivers/Cache_file.php index 13e2d1af6..edb48acb6 100644 --- a/system/libraries/Cache/drivers/Cache_file.php +++ b/system/libraries/Cache/drivers/Cache_file.php @@ -157,16 +157,15 @@ class CI_Cache_file extends CI_Driver { if (is_array($data)) { - $data = $data['data']; $mtime = filemtime($this->_cache_path.$id); - if ( ! isset($data['ttl'])) + if ( ! isset($data['data']['ttl'])) { return FALSE; } return array( - 'expire' => $mtime + $data['ttl'], + 'expire' => $mtime + $data['data']['ttl'], 'mtime' => $mtime ); } |