Code Duplication    Length = 4-4 lines in 2 locations

class/Form/FormFileCheckBox.php 1 location

@@ 45-48 (lines=4) @@
42
    public function render()
43
    {
44
        $ret = '';
45
        if (count($this->getOptions()) > 1 && '[]' !== substr($this->getName(), -2, 2)) {
46
            $newname = $this->getName() . '[]';
47
            $this->setName($newname);
48
        }
49
        foreach ($this->getOptions() as $value => $name) {
50
            $ret .= "<input type='checkbox' name='" . $this->getName() . "' value='" . $value . "'";
51
            $ret .= ' checked';

class/Form/FormRRuleCheckBox.php 1 location

@@ 45-48 (lines=4) @@
42
    {
43
        $ret = '<table><tr>';
44
        $i   = 0;
45
        if (count($this->getOptions()) > 1 && '[]' !== substr($this->getName(), -2, 2)) {
46
            $newname = $this->getName() . '[]';
47
            $this->setName($newname);
48
        }
49
        foreach ($this->getOptions() as $value => $name) {
50
            if (0 == (++$i) % 6) {
51
                $ret .= '</tr><tr>';