/** * {@inheritdoc} */ public function importDelete($name, Config $new_config, Config $old_config) { // If the field storage has been deleted in the same import, the field will // be deleted by then, and there is nothing left to do. Just return TRUE so // that the file does not get written to active store. if (!$old_config->get()) { return TRUE; } return parent::importDelete($name, $new_config, $old_config); }
/** * Constructs a BaseFieldOverrideStorage object. * * @param \Drupal\Core\Entity\EntityTypeInterface $entity_type * The entity type definition. * @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory * The config factory service. * @param \Drupal\Component\Uuid\UuidInterface $uuid_service * The UUID service. * @param \Drupal\Core\Language\LanguageManagerInterface $language_manager * The language manager. * @param \Drupal\Core\Field\FieldTypePluginManagerInterface $field_type_manager * The field type plugin manager. */ public function __construct(EntityTypeInterface $entity_type, ConfigFactoryInterface $config_factory, UuidInterface $uuid_service, LanguageManagerInterface $language_manager, FieldTypePluginManagerInterface $field_type_manager) { parent::__construct($entity_type, $config_factory, $uuid_service, $language_manager); $this->fieldTypeManager = $field_type_manager; }