Update to Drupal 8.0.0-beta15. For more information, see: https://www.drupal.org/node/2563023

This commit is contained in:
Pantheon Automation 2015-09-04 13:20:09 -07:00 committed by Greg Anderson
parent 2720a9ec4b
commit f3791f1da3
1898 changed files with 54300 additions and 11481 deletions

View file

@ -194,15 +194,12 @@ class ContentLanguageSettings extends ConfigEntityBase implements ContentLanguag
*/
public function calculateDependencies() {
parent::calculateDependencies();
$bundle_entity_type_id = $this->entityManager()->getDefinition($this->target_entity_type_id)->getBundleEntityType();
if ($bundle_entity_type_id != 'bundle') {
// If the target entity type uses entities to manage its bundles then
// depend on the bundle entity.
if (!$bundle_entity = $this->entityManager()->getStorage($bundle_entity_type_id)->load($this->target_bundle)) {
throw new \LogicException("Missing bundle entity, entity type $bundle_entity_type_id, entity id {$this->target_bundle}.");
}
$this->addDependency('config', $bundle_entity->getConfigDependencyName());
}
// Create dependency on the bundle.
$entity_type = \Drupal::entityManager()->getDefinition($this->target_entity_type_id);
$bundle_config_dependency = $entity_type->getBundleConfigDependency($this->target_bundle);
$this->addDependency($bundle_config_dependency['type'], $bundle_config_dependency['name']);
return $this->dependencies;
}