From 67ac7fdbd20a34da91e3a6c96ef25e8d3d272ace Mon Sep 17 00:00:00 2001 From: d3f3kt Date: Fri, 25 Sep 2015 19:31:19 +0200 Subject: [PATCH] fix: make it possible to use general stats --- Cache/LoggingMemcache.php | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/Cache/LoggingMemcache.php b/Cache/LoggingMemcache.php index 14efe56..9de5036 100644 --- a/Cache/LoggingMemcache.php +++ b/Cache/LoggingMemcache.php @@ -158,7 +158,11 @@ public function getStats($type='',$slabid=0,$limit=100) { $arguments = array($type,$slabid,$limit); } list($_type,$_slabid,$_limit) = array($type,$slabid,$limit); - $result = parent::getStats($_type,$_slabid,$_limit); + if ($_type == '') { + $result = parent::getStats(); + } else { + $result = parent::getStats($_type, $_slabid, $_limit); + } list($type,$slabid,$limit) = array($_type,$_slabid,$_limit); if ($this->logging) { $time = microtime(true) - $start; @@ -173,7 +177,11 @@ public function getExtendedStats($type='',$slabid=0,$limit=100) { $arguments = array($type,$slabid,$limit); } list($_type,$_slabid,$_limit) = array($type,$slabid,$limit); - $result = parent::getExtendedStats($_type,$_slabid,$_limit); + if ($_type == '') { + $result = parent::getExtendedStats(); + } else { + $result = parent::getExtendedStats($_type, $_slabid, $_limit); + } list($type,$slabid,$limit) = array($_type,$_slabid,$_limit); if ($this->logging) { $time = microtime(true) - $start;