Code Duplication    Length = 14-14 lines in 2 locations

src/Arrayy.php 2 locations

@@ 5516-5529 (lines=14) @@
5513
     *
5514
     * @return bool
5515
     */
5516
    public function sizeIsGreaterThan(int $size): bool
5517
    {
5518
        // init
5519
        $itemsTempCount = 0;
5520
5521
        foreach ($this->getGenerator() as $key => $value) {
5522
            ++$itemsTempCount;
5523
            if ($itemsTempCount > $size) {
5524
                return true;
5525
            }
5526
        }
5527
5528
        return $itemsTempCount > $size;
5529
    }
5530
5531
    /**
5532
     * Checks whether array has less than $size items.
@@ 5538-5551 (lines=14) @@
5535
     *
5536
     * @return bool
5537
     */
5538
    public function sizeIsLessThan(int $size): bool
5539
    {
5540
        // init
5541
        $itemsTempCount = 0;
5542
5543
        foreach ($this->getGenerator() as $key => $value) {
5544
            ++$itemsTempCount;
5545
            if ($itemsTempCount > $size) {
5546
                return false;
5547
            }
5548
        }
5549
5550
        return $itemsTempCount < $size;
5551
    }
5552
5553
    /**
5554
     * Counts all elements in an array, or something in an object.