Code Duplication    Length = 4-4 lines in 3 locations

xoops_trust_path/libs/altsys/class/MyBlocksAdmin.class.php 1 location

@@ 90-93 (lines=4) @@
87
    if ($xoopsModule->getVar('dirname') == 'altsys') {
88
        // set target_module if specified by $_GET['dirname']
89
        $module_handler = xoops_gethandler('module');
90
        if (! empty($_GET['dirname'])) {
91
            $dirname = preg_replace('/[^0-9a-zA-Z_-]/', '', $_GET['dirname']) ;
92
            $target_module =& $module_handler->getByDirname($dirname) ;
93
        }
94
95
        if (is_object(@$target_module)) {
96
            // module's blocks

xoops_trust_path/libs/altsys/mylangadmin.php 1 location

@@ 42-45 (lines=4) @@
39
40
// set target_module if specified by $_GET['dirname']
41
$module_handler = xoops_gethandler('module');
42
if (! empty($_GET['dirname'])) {
43
    $dirname = preg_replace('/[^0-9a-zA-Z_-]/', '', $_GET['dirname']) ;
44
    $target_module =& $module_handler->getByDirname($dirname) ;
45
}
46
47
if (! empty($target_module) && is_object($target_module)) {
48
    // specified by dirname (for langadmin as an independent module)

xoops_trust_path/libs/altsys/mytplsadmin.php 1 location

@@ 40-43 (lines=4) @@
37
38
// set target_module if specified by $_GET['dirname']
39
$module_handler = xoops_gethandler('module');
40
if (! empty($_GET['dirname'])) {
41
    $dirname = preg_replace('/[^0-9a-zA-Z_-]/', '', $_GET['dirname']) ;
42
    $target_module =& $module_handler->getByDirname($dirname) ;
43
}
44
45
if (! empty($target_module) && is_object($target_module)) {
46
    // specified by dirname (for tplsadmin as an independent module)