Code Duplication    Length = 3-3 lines in 2 locations

htdocs/themes/xbootstrap/modules/publisher/xoops_and_module_changes/modules/publisher/class/item.php 2 locations

@@ 1790-1792 (lines=3) @@
1787
            return $ret;
1788
        }
1789
        if (!$inSubCat) {
1790
            while ($row = $this->db->fetchArray($result)) {
1791
                $catsCount[$row['categoryid']] = $row['count'];
1792
            }
1793
1794
            return $catsCount;
1795
        }
@@ 1796-1798 (lines=3) @@
1793
1794
            return $catsCount;
1795
        }
1796
        while ($row = $this->db->fetchArray($result)) {
1797
            $catsCount[$row['parentid']][$row['categoryid']] = $row['count'];
1798
        }
1799
        $resultCatCounts = array();
1800
        foreach ($catsCount[0] as $subCatId => $count) {
1801
            $resultCatCounts[$subCatId] = $count;