src/EventSubscriber/Product/ProductSymbolResourceSubscriber.php line 30
<?phpnamespace App\EventSubscriber\Product;use Symfony\Component\HttpFoundation\RequestStack;use Symfony\Component\EventDispatcher\EventSubscriberInterface;use Symfony\Component\EventDispatcher\GenericEvent;use Webmozart\Assert\Assert;use Sylius\Component\Customer\Model\CustomerInterface;use App\Repository\Customer\CustomerRepository;use App\Entity\Channel\ChannelEcodaAccountInfo;use App\Entity\Product\ProductSymbol;use App\Repository\Channel\ChannelEcodaAccountInfoRepository;use App\Repository\Channel\ChannelEcodaAccountTypeRepository;use Doctrine\ORM\EntityManagerInterface;use Symfony\Component\Security\Core\Authorization\AuthorizationCheckerInterface;use Symfony\Component\Security\Core\Authentication\Token\Storage\TokenStorageInterface;use App\Manager\EcodaAccountManager;use App\Entity\Product\ProductVariant;class ProductSymbolResourceSubscriber implements EventSubscriberInterface{public function onAppEntityPreCreate(GenericEvent $event){$entity = $event->getSubject();Assert::isInstanceOf($entity, ProductSymbol::class);}public function onAppEntityPreUpdate(GenericEvent $event){$entity = $event->getSubject();Assert::isInstanceOf($entity, ProductSymbol::class);}public static function getSubscribedEvents(){return ['app.product_symbol.pre_create' => 'onAppEntityPreCreate','app.product_symbol.pre_update' => 'onAppEntityPreUpdate',];}}