From 1ec0d74e770640ac4a7cc1254c7519baa2ffd083 Mon Sep 17 00:00:00 2001 From: Kijin Sung Date: Tue, 12 Sep 2023 21:25:06 +0900 Subject: [PATCH] Fix #2062 delete references to themes in skin config --- .../integration_search.class.php | 39 ++----------------- modules/member/member.class.php | 27 ------------- modules/message/message.class.php | 29 +------------- 3 files changed, 5 insertions(+), 90 deletions(-) diff --git a/modules/integration_search/integration_search.class.php b/modules/integration_search/integration_search.class.php index 90ece1d5d..3d143ca29 100644 --- a/modules/integration_search/integration_search.class.php +++ b/modules/integration_search/integration_search.class.php @@ -24,26 +24,13 @@ class integration_search extends ModuleObject * * @return bool */ - function checkUpdate() + function checkUpdate() { - $oModuleModel = getModel('module'); - $config = $oModuleModel->getModuleConfig('integration_search'); - - if($config->skin) - { - $config_parse = explode('.', $config->skin); - if(count($config_parse) > 1) - { - $template_path = sprintf('./themes/%s/modules/integration_search/', $config_parse[0]); - if(is_dir($template_path)) return true; - } - } - if (!ModuleModel::getActionForward('IS')) { return true; } - + return false; } @@ -52,29 +39,11 @@ class integration_search extends ModuleObject * * @return Object */ - function moduleUpdate() + function moduleUpdate() { - $oModuleModel = getModel('module'); - $config = $oModuleModel->getModuleConfig('message'); - - if($config->skin) - { - $config_parse = explode('.', $config->skin); - if(count($config_parse) > 1) - { - $template_path = sprintf('./themes/%s/modules/integration_search/', $config_parse[0]); - if(is_dir($template_path)) - { - $config->skin = implode('|@|', $config_parse); - $oModuleController = getController('module'); - $oModuleController->updateModuleConfig('integration_search', $config); - } - } - } - if (!ModuleModel::getActionForward('IS')) { - $oModuleController = getController('module'); + $oModuleController = ModuleController::getInstance(); $oModuleController->insertActionForward('integration_search', 'view', 'IS'); } } diff --git a/modules/member/member.class.php b/modules/member/member.class.php index e8ab501e2..976688efb 100644 --- a/modules/member/member.class.php +++ b/modules/member/member.class.php @@ -228,17 +228,6 @@ class Member extends ModuleObject return true; } - // Check skin - if($config->skin) - { - $config_parse = explode('.', $config->skin); - if(count($config_parse) > 1) - { - $template_path = sprintf('./themes/%s/modules/member/', $config_parse[0]); - if(is_dir($template_path)) return true; - } - } - // supprot multilanguage agreement. if(FileHandler::exists('./files/member_extra_info/agreement.txt')) return true; if(FileHandler::exists('./files/ruleset/insertMember.xml')) return true; @@ -550,22 +539,6 @@ class Member extends ModuleObject $oModuleController->updateModuleConfig('member', $config); } - // Check skin - if($config->skin) - { - $config_parse = explode('.', $config->skin); - if (count($config_parse) > 1) - { - $template_path = sprintf('./themes/%s/modules/member/', $config_parse[0]); - if(is_dir($template_path)) - { - $config->skin = implode('|@|', $config_parse); - $oModuleController = getController('module'); - $oModuleController->updateModuleConfig('member', $config); - } - } - } - if(file_exists('./files/member_extra_info/agreement.txt')) { $source_file = RX_BASEDIR.'files/member_extra_info/agreement.txt'; diff --git a/modules/message/message.class.php b/modules/message/message.class.php index 925fa9cb4..6142a31cd 100644 --- a/modules/message/message.class.php +++ b/modules/message/message.class.php @@ -20,19 +20,7 @@ class Message extends ModuleObject */ function checkUpdate() { - $oModuleModel = getModel('module'); - $config = $oModuleModel->getModuleConfig('message'); - if(!empty($config->skin)) - { - $config_parse = explode('.', $config->skin); - if (count($config_parse) > 1) - { - $template_path = sprintf('./themes/%s/modules/message/', $config_parse[0]); - if(is_dir($template_path)) return true; - } - } - return false; } /** @@ -40,23 +28,7 @@ class Message extends ModuleObject */ function moduleUpdate() { - $oModuleModel = getModel('module'); - $config = $oModuleModel->getModuleConfig('message'); - if($config->skin) - { - $config_parse = explode('.', $config->skin); - if (count($config_parse) > 1) - { - $template_path = sprintf('./themes/%s/modules/message/', $config_parse[0]); - if(is_dir($template_path)) - { - $config->skin = implode('|@|', $config_parse); - $oModuleController = getController('module'); - $oModuleController->updateModuleConfig('message', $config); - } - } - } } /** @@ -64,6 +36,7 @@ class Message extends ModuleObject */ function recompileCache() { + } } /* End of file message.class.php */