diff --git a/hwe/j_install_db.php b/hwe/j_install_db.php index c6eb110e..44f18e79 100644 --- a/hwe/j_install_db.php +++ b/hwe/j_install_db.php @@ -87,6 +87,20 @@ if($result !== true){ } if (!class_exists('\\sammo\\DB')) { + $loader = require __DIR__.'/../vendor/autoload.php'; + $loader->addClassMap((function () { + $d_settingMap = []; + foreach (glob(__DIR__.'/d_setting/*.orig.php') as $filepath) { + $filepath = str_replace('.orig.php', '.php', $filepath); + if(!file_exists($filepath)) { + continue; + } + $filename = basename($filepath); + $classname = explode('.', $filename)[0]; + $d_settingMap['sammo\\'.$classname] = $filepath; + }; + return $d_settingMap; + })()); opcache_reset(); }