From e3016b7a77f39f2aa63fb0697faca3e86339a929 Mon Sep 17 00:00:00 2001 From: thisgun Date: Wed, 25 May 2022 18:57:16 +0900 Subject: [PATCH] =?UTF-8?q?object=20cache=EB=A5=BC=20=EC=82=AD=EC=A0=9C?= =?UTF-8?q?=ED=95=98=EC=A7=80=20=EB=AA=BB=ED=95=A0=EC=88=98=EC=9E=88?= =?UTF-8?q?=EB=8A=94=20=EB=B2=84=EA=B7=B8=EC=88=98=EC=A0=95=20#190?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/Cache/obj.class.php | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/lib/Cache/obj.class.php b/lib/Cache/obj.class.php index b75cf0980..ee6bcebcf 100644 --- a/lib/Cache/obj.class.php +++ b/lib/Cache/obj.class.php @@ -6,7 +6,7 @@ Class G5_object_cache { public $contents = array(); public $etcs = array(); - function get($type, $key, $group ='default') { + function get($type, $key, $group ='default') { switch ($type) { case 'bbs': @@ -28,10 +28,10 @@ Class G5_object_cache { } return false; - } + } + + function exists($type, $key, $group = 'default' ) { - function exists($type, $key, $group = 'default' ) { - $return_data = ''; switch ($type) { @@ -47,9 +47,9 @@ Class G5_object_cache { } return isset($datas[$group]) && ( isset($datas[$group][$key]) || array_key_exists($key, $datas[$group]) ); - } + } - function set($type, $key, $data=array(), $group='default') { + function set($type, $key, $data=array(), $group='default') { if ( is_object( $data ) ) $data = clone $data; @@ -65,10 +65,10 @@ Class G5_object_cache { break; } - } + } function delete($key, $group='default') { - switch ($type) { + switch ($key) { case 'bbs': $datas = $this->writes; break;