mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-03 09:14:48 +09:00
#18366896 : fixed a bug occurred when non-modules are put into modules directory
git-svn-id: http://xe-core.googlecode.com/svn/sandbox@6879 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
31d00efa0f
commit
e97407dc1f
2 changed files with 9 additions and 3 deletions
|
|
@ -334,7 +334,6 @@
|
||||||
|
|
||||||
// if there is no instance of the module in global variable, create a new one
|
// if there is no instance of the module in global variable, create a new one
|
||||||
if(!$GLOBALS['_loaded_module'][$module][$type][$kind]) {
|
if(!$GLOBALS['_loaded_module'][$module][$type][$kind]) {
|
||||||
|
|
||||||
// Get base class name and load the file contains it
|
// Get base class name and load the file contains it
|
||||||
if(!class_exists($module)) {
|
if(!class_exists($module)) {
|
||||||
$high_class_file = sprintf('%s%s%s.class.php', _XE_PATH_,$class_path, $module);
|
$high_class_file = sprintf('%s%s%s.class.php', _XE_PATH_,$class_path, $module);
|
||||||
|
|
@ -395,6 +394,7 @@
|
||||||
|
|
||||||
// Create an instance with eval function
|
// Create an instance with eval function
|
||||||
require_once($class_file);
|
require_once($class_file);
|
||||||
|
if(!class_exists($instance_name)) return NULL;
|
||||||
$eval_str = sprintf('$oModule = new %s();', $instance_name);
|
$eval_str = sprintf('$oModule = new %s();', $instance_name);
|
||||||
@eval($eval_str);
|
@eval($eval_str);
|
||||||
if(!is_object($oModule)) return NULL;
|
if(!is_object($oModule)) return NULL;
|
||||||
|
|
@ -430,7 +430,7 @@
|
||||||
* @return Object
|
* @return Object
|
||||||
**/
|
**/
|
||||||
function triggerCall($trigger_name, $called_position, &$obj) {
|
function triggerCall($trigger_name, $called_position, &$obj) {
|
||||||
// 설치가 안되어 있다면 trigger call을 하지 않고 바로 return
|
// skip if not installed
|
||||||
if(!Context::isInstalled()) return new Object();
|
if(!Context::isInstalled()) return new Object();
|
||||||
|
|
||||||
$oModuleModel = &getModel('module');
|
$oModuleModel = &getModel('module');
|
||||||
|
|
|
||||||
|
|
@ -949,7 +949,13 @@
|
||||||
// 각 모듈의 module.class.php로 upgrade 유무 체크
|
// 각 모듈의 module.class.php로 upgrade 유무 체크
|
||||||
$oDummy = null;
|
$oDummy = null;
|
||||||
$oDummy = &getModule($module_name, 'class');
|
$oDummy = &getModule($module_name, 'class');
|
||||||
if($oDummy) $info->need_update = $oDummy->checkUpdate();
|
if($oDummy && method_exists($oDummy, "checkUpdate")) {
|
||||||
|
$info->need_update = $oDummy->checkUpdate();
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
continue;
|
||||||
|
}
|
||||||
|
|
||||||
$list[] = $info;
|
$list[] = $info;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue