Setono / SyliusGiftCardPlugin

Sell gift cards on your Sylius store and let users use them in the checkout process
MIT License
45 stars 39 forks source link

Fix service replacement in Sylius 1.11 #203

Closed loevgaard closed 2 years ago

loevgaard commented 2 years ago

In Sylius 1.11 the service sylius.api.context.user is replaced by Sylius\Bundle\ApiBundle\Context\UserContextInterface (see https://github.com/Sylius/Sylius/blob/master/UPGRADE-API-1.11.md). Because we don't have Sylius requirements in our composer.json, my suggestion is to define the service sylius.api.context.user if it doesn't exist and alias it to Sylius\Bundle\ApiBundle\Context\UserContextInterface