Setono / SyliusMailchimpPlugin

Mailchimp integration plugin for Sylius
MIT License
11 stars 14 forks source link

Support product variants with no name #54

Closed mmenozzi closed 3 years ago

mmenozzi commented 3 years ago

Currently if a product variant has no name (and this is allowed by Sylius) the push orders command fails if an order contains such variants.

mmenozzi commented 3 years ago

I cannot work on a fix right now but a quick solution to this could be a change from this:

https://github.com/Setono/SyliusMailchimpPlugin/blob/23544e597aa1bc33d8eb2d2824d1491329a7a90f/src/DataGenerator/ProductVariantDataGenerator.php#L33

to this:

'title' => $productVariant->getName() ?? $productVariant->getProduct()->getName(), 
mmenozzi commented 3 years ago

Thank you guys!