Code Duplication    Length = 5-7 lines in 2 locations

src/Phossa2/Query/Traits/Clause/LimitTrait.php 2 locations

@@ 38-44 (lines=7) @@
35
    public function limit(/*# int */ $count, /*# int */ $offset = 0)
36
    {
37
        $clause = &$this->getClause('LIMIT');
38
        if ($count || $offset) {
39
            if (!empty($clause)) {
40
                $clause[0] = (int) $count;
41
            } else {
42
                $clause = [(int) $count, (int) $offset];
43
            }
44
        }
45
        return $this;
46
    }
47
@@ 54-58 (lines=5) @@
51
    public function offset(/*# int */ $offset)
52
    {
53
        $clause = &$this->getClause('LIMIT');
54
        if (!empty($clause)) {
55
            $clause[1] = (int) $offset;
56
        } else {
57
            $clause = [-1, (int) $offset];
58
        }
59
        return $this;
60
    }
61