changed categories to hash