mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-05 09:41:40 +09:00
fix #445 APC에서 delete()가 null을 삽입하는 문제 수정
This commit is contained in:
parent
9af3c9efc1
commit
ad0144b4e1
1 changed files with 10 additions and 15 deletions
25
classes/cache/CacheApc.class.php
vendored
25
classes/cache/CacheApc.class.php
vendored
|
|
@ -84,7 +84,7 @@ class CacheApc extends CacheBase
|
|||
|
||||
if($modified_time > 0 && $modified_time > $obj[0])
|
||||
{
|
||||
$this->_delete($_key);
|
||||
$this->delete($_key);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
|
@ -110,24 +110,13 @@ class CacheApc extends CacheBase
|
|||
|
||||
if($modified_time > 0 && $modified_time > $obj[0])
|
||||
{
|
||||
$this->_delete($_key);
|
||||
$this->delete($_key);
|
||||
return false;
|
||||
}
|
||||
|
||||
return $obj[1];
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete variable from the cache(private)
|
||||
*
|
||||
* @param string $_key Used to store the value.
|
||||
* @return void
|
||||
*/
|
||||
function _delete($_key)
|
||||
{
|
||||
$this->put($_key, null, 1);
|
||||
}
|
||||
|
||||
/**
|
||||
* Delete variable from the cache
|
||||
*
|
||||
|
|
@ -136,7 +125,7 @@ class CacheApc extends CacheBase
|
|||
*/
|
||||
function delete($key)
|
||||
{
|
||||
$this->_delete($key);
|
||||
return apc_delete($key);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -149,7 +138,13 @@ class CacheApc extends CacheBase
|
|||
return apc_clear_cache('user');
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @DEPRECATED
|
||||
*/
|
||||
function _delete($key)
|
||||
{
|
||||
return $this->delete($key);
|
||||
}
|
||||
}
|
||||
|
||||
CacheApc::$isSupport = function_exists('apc_add');
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue