diff --git a/core/modules/content_translation/content_translation.pages.inc b/core/modules/content_translation/content_translation.pages.inc index f4eba85..afd409a 100644 --- a/core/modules/content_translation/content_translation.pages.inc +++ b/core/modules/content_translation/content_translation.pages.inc @@ -275,7 +275,7 @@ function content_translation_delete_confirm_submit(array $form, array &$form_sta $controller = content_translation_controller($entity->entityType()); // Remove the translated values. - $controller->removeTranslation($entity, $language->id); + $entity->removeTranslation($language->id); $entity->save(); // Remove any existing path alias for the removed translation. diff --git a/core/modules/content_translation/lib/Drupal/content_translation/ContentTranslationController.php b/core/modules/content_translation/lib/Drupal/content_translation/ContentTranslationController.php index acdafb0..8fb88cb 100644 --- a/core/modules/content_translation/lib/Drupal/content_translation/ContentTranslationController.php +++ b/core/modules/content_translation/lib/Drupal/content_translation/ContentTranslationController.php @@ -43,13 +43,6 @@ public function __construct($entity_type, $entity_info) { } /** - * {@inheritdoc} - */ - public function removeTranslation(EntityInterface $entity, $langcode) { - $entity->removeTranslation($langcode); - } - - /** * Implements ContentTranslationControllerInterface::retranslate(). */ public function retranslate(EntityInterface $entity, $langcode = NULL) { diff --git a/core/modules/content_translation/lib/Drupal/content_translation/ContentTranslationControllerInterface.php b/core/modules/content_translation/lib/Drupal/content_translation/ContentTranslationControllerInterface.php index 109747e..d046655 100644 --- a/core/modules/content_translation/lib/Drupal/content_translation/ContentTranslationControllerInterface.php +++ b/core/modules/content_translation/lib/Drupal/content_translation/ContentTranslationControllerInterface.php @@ -140,16 +140,6 @@ public function getTranslationAccess(EntityInterface $entity, $op); public function getSourceLangcode(array $form_state); /** - * Removes the translation values from the given entity. - * - * @param \Drupal\Core\Entity\EntityInterface $entity - * The entity whose values should be removed. - * @param string $langcode - * The language code identifying the translation being deleted. - */ - public function removeTranslation(EntityInterface $entity, $langcode); - - /** * Marks translations as outdated. * * @param \Drupal\Core\Entity\EntityInterface $entity