From 9e6fdda71cf70275fcf7e4b09230daa713c18b70 Mon Sep 17 00:00:00 2001 From: wei <> Date: Sat, 20 Jan 2007 23:46:35 +0000 Subject: minor changes to active record meta data inspector --- framework/Caching/TAPCCache.php | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) (limited to 'framework/Caching') diff --git a/framework/Caching/TAPCCache.php b/framework/Caching/TAPCCache.php index fb419911..969de4a4 100644 --- a/framework/Caching/TAPCCache.php +++ b/framework/Caching/TAPCCache.php @@ -54,9 +54,12 @@ class TAPCCache extends TCache */ public function init($config) { - if(!extension_loaded('apc')) - throw new TConfigurationException('apccache_extension_required'); - parent::init($config); + if(substr(php_sapi_name(), 0, 3) !== 'cli') //APC is usually disabled in CLI mode. + { + if(!extension_loaded('apc')) + throw new TConfigurationException('apccache_extension_required'); + parent::init($config); + } } /** -- cgit v1.2.3