X-Git-Url: http://www.aleph1.co.uk/gitweb/?p=yaffs-website;a=blobdiff_plain;f=web%2Fcore%2Flib%2FDrupal%2FCore%2FEntity%2FEntity%2FEntityViewDisplay.php;fp=web%2Fcore%2Flib%2FDrupal%2FCore%2FEntity%2FEntity%2FEntityViewDisplay.php;h=7c7d62e04da3bfe0f5851b67efacbc7110cd41a6;hp=74b15b65f4754ebff62267a668027cc4ba52c9e6;hb=af6d1fb995500ae68849458ee10d66abbdcfb252;hpb=680c79a86e3ed402f263faeac92e89fb6d9edcc0 diff --git a/web/core/lib/Drupal/Core/Entity/Entity/EntityViewDisplay.php b/web/core/lib/Drupal/Core/Entity/Entity/EntityViewDisplay.php index 74b15b65f..7c7d62e04 100644 --- a/web/core/lib/Drupal/Core/Entity/Entity/EntityViewDisplay.php +++ b/web/core/lib/Drupal/Core/Entity/Entity/EntityViewDisplay.php @@ -8,7 +8,7 @@ use Drupal\Core\Entity\EntityDisplayPluginCollection; use Drupal\Core\Entity\EntityStorageInterface; use Drupal\Core\Entity\FieldableEntityInterface; use Drupal\Core\Entity\EntityDisplayBase; -use Drupal\Core\TypedData\TranslatableInterface; +use Drupal\Core\TypedData\TranslatableInterface as TranslatableDataInterface; /** * Configuration entity that contains display options for all components of a @@ -21,6 +21,9 @@ use Drupal\Core\TypedData\TranslatableInterface; * "id" = "id", * "status" = "status" * }, + * handlers = { + * "access" = "\Drupal\Core\Entity\Entity\Access\EntityViewDisplayAccessControlHandler", + * }, * config_export = { * "id", * "targetEntityType", @@ -250,7 +253,7 @@ class EntityViewDisplay extends EntityDisplayBase implements EntityViewDisplayIn // those values using: // - the entity language if the entity is translatable, // - the current "content language" otherwise. - if ($entity instanceof TranslatableInterface && $entity->isTranslatable()) { + if ($entity instanceof TranslatableDataInterface && $entity->isTranslatable()) { $view_langcode = $entity->language()->getId(); } else {