Code Duplication    Length = 17-17 lines in 2 locations

src/voku/db/Result.php 2 locations

@@ 648-664 (lines=17) @@
645
     *
646
     * @return array|false <p><strong>false</strong> on error</p>
647
     */
648
    public function fetchArray(bool $reset = false)
649
    {
650
        if ($reset === true) {
651
            $this->reset();
652
        }
653
654
        $row = $this->fetch_assoc();
655
        if ($row) {
656
            return $this->cast($row);
657
        }
658
659
        if ($row === null || $row === false) {
660
            return [];
661
        }
662
663
        return false;
664
    }
665
666
    /**
667
     * Fetch data as a key/value pair array.
@@ 714-730 (lines=17) @@
711
     *
712
     * @return Arrayy|false <p><strong>false</strong> on error</p>
713
     */
714
    public function fetchArrayy(bool $reset = false)
715
    {
716
        if ($reset === true) {
717
            $this->reset();
718
        }
719
720
        $row = $this->fetch_assoc();
721
        if ($row) {
722
            return Arrayy::create($this->cast($row));
723
        }
724
725
        if ($row === null || $row === false) {
726
            return Arrayy::create();
727
        }
728
729
        return false;
730
    }
731
732
    /**
733
     * Fetches a row or a single column within a row. Returns null if there are