fix: resolve TypeScript iterator error in OutfitRecommendationTool
- Fixed type error where response.recommendations could be undefined - Added null coalescing operator to ensure safe array spreading - Updated OutfitRecommendationCard and capabilities configuration
This commit is contained in:
@@ -142,7 +142,7 @@ const OutfitRecommendationTool: React.FC = () => {
|
||||
if (group.group_id === groupId) {
|
||||
return {
|
||||
...group,
|
||||
children: [...group.children, ...response.recommendations]
|
||||
children: [...group.children, ...(response.recommendations || [])]
|
||||
};
|
||||
}
|
||||
return group;
|
||||
|
||||
Reference in New Issue
Block a user