Hello!
I’m using the Square PHP SDK v33.1.0.20231213
I have an existing ITEM that has 1 CATEGORY.
I set a different CATEGORY to the one above in the following code:
$catalogObject->getItemData()->setCategories([$catalogObjectCategory])
I expect the result to replace what I have provided in the ->setCategories()
method, however when I log in to the Square Dashboard, the ITEM has both the old and new CATEGORY.
Am I missing something or misunderstanding the documentation? How do I remove the existing categories and add new and different categories to the item?