Merge pull request #113 from openclassify/vedat

repair parent category
This commit is contained in:
Fatih Alp 2019-10-18 17:50:43 +03:00 committed by GitHub
commit 4a6eedf752
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -43,7 +43,8 @@ class CategoryModel extends CatsCategoryEntryModel implements CategoryInterface
public function getCatLevel($id)
{
return count($this->getParentCats($id));
//count parent and itself
return count($this->getParentCats($id))+1;
}
public function getSubCategories($id, $get = null)