You are here

function language_entity_bundle_delete in Drupal 8

Same name and namespace in other branches
  1. 9 core/modules/language/language.module \language_entity_bundle_delete()

Implements hook_entity_bundle_delete().

File

core/modules/language/language.module, line 217
Add language handling functionality to Drupal.

Code

function language_entity_bundle_delete($entity_type_id, $bundle) {

  // Remove the content language settings associated with the bundle.
  $settings = ContentLanguageSettings::loadByEntityTypeBundle($entity_type_id, $bundle);
  if (!$settings
    ->isNew()) {
    $settings
      ->delete();
  }
}