Code Duplication    Length = 3-5 lines in 2 locations

htdocs/install/class/pathcontroller.php 1 location

@@ 69-71 (lines=3) @@
66
            }
67
        } else {
68
            $path = str_replace("\\", '/', realpath('../'));
69
            if (substr($path, -1) === '/') {
70
                $path = substr($path, 0, -1);
71
            }
72
            if (file_exists("$path/mainfile.dist.php")) {
73
                $this->xoopsPath['root'] = $path;
74
            }

htdocs/xoops_lib/modules/protector/library/HTMLPurifier/Lexer/DOMLex.php 1 location

@@ 155-159 (lines=5) @@
152
                $new_data = trim($data);
153
                if (substr($new_data, 0, 4) === '<!--') {
154
                    $data = substr($new_data, 4);
155
                    if (substr($data, -3) === '-->') {
156
                        $data = substr($data, 0, -3);
157
                    } else {
158
                        // Highly suspicious! Not sure what to do...
159
                    }
160
                }
161
            }
162
            $tokens[] = $this->factory->createText($this->parseText($data, $config));