fixed getSubCategoryById()

* if amount of subcategories is 0, null gets returned