Code Duplication    Length = 18-18 lines in 2 locations

htdocs/modules/protector/class/protector.php 1 location

@@ 500-517 (lines=18) @@
497
        return $this->_dblayertrap_doubtfuls;
498
    }
499
500
    function _dblayertrap_check_recursive($val)
501
    {
502
        if (is_array($val)) {
503
            foreach ($val as $subval) {
504
                $this->_dblayertrap_check_recursive($subval);
505
            }
506
        } else {
507
            if (strlen($val) < 6) {
508
                return;
509
            }
510
            $val = get_magic_quotes_gpc() ? stripslashes($val) : $val;
511
            foreach ($this->_dblayertrap_doubtful_needles as $needle) {
512
                if (stristr($val, $needle)) {
513
                    $this->_dblayertrap_doubtfuls[] = $val;
514
                }
515
            }
516
        }
517
    }
518
519
    function dblayertrap_init($force_override = false)
520
    {

htdocs/modules/protector/class/ProtectorDatabaseLayer.php 1 location

@@ 67-84 (lines=18) @@
64
     * @param $val
65
     * @return void
66
     */
67
    protected function dbLayerTrapCheckRecursive($val)
68
    {
69
        if (is_array($val)) {
70
            foreach ($val as $subval) {
71
                $this->dbLayerTrapCheckRecursive($subval);
72
            }
73
        } else {
74
            if (strlen($val) < 6) {
75
                return;
76
            }
77
            $val = get_magic_quotes_gpc() ? stripslashes($val) : $val;
78
            foreach ($this->dbLayerTrapDoubtfulNeedles as $needle) {
79
                if (false !== stripos($val, $needle)) {
80
                    $this->dbLayerTrapDoubtfuls[] = $val;
81
                }
82
            }
83
        }
84
    }
85
86
    /**
87
     * @param  bool $force_override