Commit 278e74c9 authored by catch's avatar catch
Browse files

Issue #3026166 by Berdir: Remove unnecessary...

Issue #3026166 by Berdir: Remove unnecessary EntityTypeManager::clearCachedDefinitions() calls in content_translation
parent f570135a
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -401,7 +401,6 @@ function content_translation_form_language_content_settings_submit(array $form,
    }
  }

  // Ensure entity and menu router information are correctly rebuilt.
  \Drupal::entityTypeManager()->clearCachedDefinitions();
  // Ensure menu router information is correctly rebuilt.
  \Drupal::service('router.builder')->setRebuildNeeded();
}
+0 −1
Original line number Diff line number Diff line
@@ -642,7 +642,6 @@ function content_translation_language_configuration_element_submit(array $form,

  if (\Drupal::service('content_translation.manager')->isEnabled($context['entity_type'], $context['bundle']) != $enabled) {
    \Drupal::service('content_translation.manager')->setEnabled($context['entity_type'], $context['bundle'], $enabled);
    \Drupal::entityTypeManager()->clearCachedDefinitions();
    \Drupal::service('router.builder')->setRebuildNeeded();
  }
}