change method name
This commit is contained in:
parent
734a51891d
commit
dd53e60eff
|
@ -43,14 +43,14 @@ class MenuEventSubscriber extends EntityManagerEventSubscriber
|
||||||
$this->translator = $translator;
|
$this->translator = $translator;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function support(EntityInterface $entity)
|
public function supports(EntityInterface $entity): bool
|
||||||
{
|
{
|
||||||
return $entity instanceof Menu;
|
return $entity instanceof Menu;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function onPreUpdate(EntityManagerEvent $event)
|
public function onPreUpdate(EntityManagerEvent $event)
|
||||||
{
|
{
|
||||||
if (!$this->support($event->getEntity())) {
|
if (!$this->supports($event->getEntity())) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -60,7 +60,7 @@ class MenuEventSubscriber extends EntityManagerEventSubscriber
|
||||||
|
|
||||||
public function onCreate(EntityManagerEvent $event)
|
public function onCreate(EntityManagerEvent $event)
|
||||||
{
|
{
|
||||||
if (!$this->support($event->getEntity())) {
|
if (!$this->supports($event->getEntity())) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -24,14 +24,14 @@ class NavigationEventSubscriber extends EntityManagerEventSubscriber
|
||||||
$this->slugify = $slugify;
|
$this->slugify = $slugify;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function support(EntityInterface $entity)
|
public function supports(EntityInterface $entity): bool
|
||||||
{
|
{
|
||||||
return $entity instanceof Navigation;
|
return $entity instanceof Navigation;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function onPreUpdate(EntityManagerEvent $event)
|
public function onPreUpdate(EntityManagerEvent $event)
|
||||||
{
|
{
|
||||||
if (!$this->support($event->getEntity())) {
|
if (!$this->supports($event->getEntity())) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -45,7 +45,7 @@ class NodeEventSubscriber extends EntityManagerEventSubscriber
|
||||||
$this->routeParameterSlugify = $routeParameterSlugify;
|
$this->routeParameterSlugify = $routeParameterSlugify;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function support(EntityInterface $entity)
|
public function supports(EntityInterface $entity): bool
|
||||||
{
|
{
|
||||||
return $entity instanceof Node;
|
return $entity instanceof Node;
|
||||||
}
|
}
|
||||||
|
@ -57,7 +57,7 @@ class NodeEventSubscriber extends EntityManagerEventSubscriber
|
||||||
|
|
||||||
public function onPreUpdate(EntityManagerEvent $event)
|
public function onPreUpdate(EntityManagerEvent $event)
|
||||||
{
|
{
|
||||||
if (!$this->support($event->getEntity())) {
|
if (!$this->supports($event->getEntity())) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -159,7 +159,7 @@ class NodeEventSubscriber extends EntityManagerEventSubscriber
|
||||||
|
|
||||||
public function onDelete(EntityManagerEvent $event)
|
public function onDelete(EntityManagerEvent $event)
|
||||||
{
|
{
|
||||||
if (!$this->support($event->getEntity())) {
|
if (!$this->supports($event->getEntity())) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -24,14 +24,14 @@ class BlockEventSubscriber extends EntityManagerEventSubscriber
|
||||||
$this->fileUpload = $fileUpload;
|
$this->fileUpload = $fileUpload;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function support(EntityInterface $entity)
|
public function supports(EntityInterface $entity): bool
|
||||||
{
|
{
|
||||||
return $entity instanceof Page;
|
return $entity instanceof Page;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function onPreUpdate(EntityManagerEvent $event)
|
public function onPreUpdate(EntityManagerEvent $event)
|
||||||
{
|
{
|
||||||
if (!$this->support($event->getEntity())) {
|
if (!$this->supports($event->getEntity())) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -23,14 +23,14 @@ class PageEventSubscriber extends EntityManagerEventSubscriber
|
||||||
$this->fileUpload = $fileUpload;
|
$this->fileUpload = $fileUpload;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function support(EntityInterface $entity)
|
public function supports(EntityInterface $entity): bool
|
||||||
{
|
{
|
||||||
return $entity instanceof Page;
|
return $entity instanceof Page;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function onPreUpdate(EntityManagerEvent $event)
|
public function onPreUpdate(EntityManagerEvent $event)
|
||||||
{
|
{
|
||||||
if (!$this->support($event->getEntity())) {
|
if (!$this->supports($event->getEntity())) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -27,14 +27,14 @@ class SiteEventSubscriber extends EntityManagerEventSubscriber
|
||||||
$this->cacheManager = $cacheManager;
|
$this->cacheManager = $cacheManager;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function support(EntityInterface $entity)
|
public function supports(EntityInterface $entity): bool
|
||||||
{
|
{
|
||||||
return $entity instanceof Node || $entity instanceof Menu || $entity instanceof Navigation;
|
return $entity instanceof Node || $entity instanceof Menu || $entity instanceof Navigation;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function onUpdate(EntityManagerEvent $event)
|
public function onUpdate(EntityManagerEvent $event)
|
||||||
{
|
{
|
||||||
if (!$this->support($event->getEntity())) {
|
if (!$this->supports($event->getEntity())) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue