Fixing conditional category output - with products, brands or child categories