Code Duplication    Length = 5-5 lines in 2 locations

external/header.php 1 location

@@ 78-82 (lines=5) @@
75
$dir = dirname(__DIR__);
76
require_once $dir . '/src/Xhgui/Config.php';
77
$configDir = defined('XHGUI_CONFIG_DIR') ? XHGUI_CONFIG_DIR : $dir . '/config/';
78
if (file_exists($configDir . 'config.php')) {
79
    Xhgui_Config::load($configDir . 'config.php');
80
} else {
81
    Xhgui_Config::load($configDir . 'config.default.php');
82
}
83
unset($dir, $configDir);
84
85
if ((!extension_loaded('mongo') && !extension_loaded('mongodb')) && Xhgui_Config::read('save.handler') === 'mongodb') {

src/bootstrap.php 1 location

@@ 18-22 (lines=5) @@
15
$dir = dirname(__DIR__);
16
require_once $dir . '/src/Xhgui/Config.php';
17
$configDir = defined('XHGUI_CONFIG_DIR') ? XHGUI_CONFIG_DIR : $dir . '/config/';
18
if (file_exists($configDir . 'config.php')) {
19
    Xhgui_Config::load($configDir . 'config.php');
20
} else {
21
    Xhgui_Config::load($configDir . 'config.default.php');
22
}
23
unset($dir, $configDir);