/** * {@inheritdoc} */ public function onEntityTypeUpdate(EntityTypeInterface $entity_type, EntityTypeInterface $original) { $entity_type_id = $entity_type->id(); // @todo Forward this to all interested handlers, not only storage, once // iterating handlers is possible: https://www.drupal.org/node/2332857. $storage = $this->entityTypeManager->getStorage($entity_type_id); if ($storage instanceof EntityTypeListenerInterface) { $storage->onEntityTypeUpdate($entity_type, $original); } $this->eventDispatcher->dispatch(EntityTypeEvents::UPDATE, new EntityTypeEvent($entity_type, $original)); $this->entityLastInstalledSchemaRepository->setLastInstalledDefinition($entity_type); }