From 00562076544d79b3570586fddb1189570106d1bf Mon Sep 17 00:00:00 2001 From: haneul Date: Tue, 28 Sep 2010 05:11:30 +0000 Subject: [PATCH] git-svn-id: http://xe-core.googlecode.com/svn/sandbox@7718 201d5d3c-b55e-5fd7-737f-ddc643e51545 --- modules/module/module.model.php | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/modules/module/module.model.php b/modules/module/module.model.php index 88850aa11..9f76c73b5 100644 --- a/modules/module/module.model.php +++ b/modules/module/module.model.php @@ -313,8 +313,9 @@ $cache_file = FileHandler::getRealPath($cache_file); if(!isset($GLOBALS['__MODULE_EXTEND__'])){ - if(!file_exists($cache_file)) { + // check pre install + if(file_exists(FileHandler::getRealPath('./files')) && !file_exists($cache_file)) { $arr = array(); $output = executeQueryArray('module.getModuleExtend'); if($output->data){ @@ -327,9 +328,13 @@ $str = sprintf($str, join(',',$arr)); FileHandler::writeFile($cache_file, $str); + + $GLOBALS['__MODULE_EXTEND__'] = include($cache_file); + + } else { + + $GLOBALS['__MODULE_EXTEND__'] = array(); } - - $GLOBALS['__MODULE_EXTEND__'] = include($cache_file); } return $GLOBALS['__MODULE_EXTEND__'];