From 021f96f2703983b9204147aa6ea107459bb5222e Mon Sep 17 00:00:00 2001 From: Christian Schneider Date: Tue, 21 Jul 2015 15:16:19 +0200 Subject: Code style simplifications --- it_cache.class | 6 ------ 1 file changed, 6 deletions(-) (limited to 'it_cache.class') diff --git a/it_cache.class b/it_cache.class index ff4dd33..e4f45c1 100644 --- a/it_cache.class +++ b/it_cache.class @@ -71,13 +71,9 @@ static function put($key, $value, $p = array()) $p = it_cache::_defaults($p); if ($p['distributed'] && ($memcache = it_cache::_get_memcache($p))) - { $success = @$memcache->set($key, $value, MEMCACHE_COMPRESSED, $p['ttl']); - } else - { $success = ($func = self::$_store_func) ? $func($key, $value, $p['ttl']) : null; - } if (!$success) it::error(array('title' => ($p['distributed'] ? "memcache" : self::$_store_func) . " in it_cache::put failed for key '$key'", 'id' => "it_cache_put", 'graceperiod' => 60, 'timewindow' => 10)); @@ -108,5 +104,3 @@ static function _get_memcache($p) it_cache::$_fetch_func = function_exists("apcu_fetch") ? "apcu_fetch" : (function_exists("apc_fetch") ? "apc_fetch" : null); it_cache::$_store_func = function_exists("apcu_store") ? "apcu_store" : (function_exists("apc_store") ? "apc_store" : null); - -?> -- cgit v1.2.3