Replacing the old the getCategories with the CategoryController list method that does the same thing.