comparison core/modules/rest/src/Plugin/Deriver/EntityDeriver.php @ 14:1fec387a4317

Update Drupal core to 8.5.2 via Composer
author Chris Cannam
date Mon, 23 Apr 2018 09:46:53 +0100
parents 4c8ae668cc8c
children
comparison
equal deleted inserted replaced
13:5fb285c0d0e3 14:1fec387a4317
63 */ 63 */
64 public function getDerivativeDefinitions($base_plugin_definition) { 64 public function getDerivativeDefinitions($base_plugin_definition) {
65 if (!isset($this->derivatives)) { 65 if (!isset($this->derivatives)) {
66 // Add in the default plugin configuration and the resource type. 66 // Add in the default plugin configuration and the resource type.
67 foreach ($this->entityManager->getDefinitions() as $entity_type_id => $entity_type) { 67 foreach ($this->entityManager->getDefinitions() as $entity_type_id => $entity_type) {
68 if ($entity_type->isInternal()) {
69 continue;
70 }
71
68 $this->derivatives[$entity_type_id] = [ 72 $this->derivatives[$entity_type_id] = [
69 'id' => 'entity:' . $entity_type_id, 73 'id' => 'entity:' . $entity_type_id,
70 'entity_type' => $entity_type_id, 74 'entity_type' => $entity_type_id,
71 'serialization_class' => $entity_type->getClass(), 75 'serialization_class' => $entity_type->getClass(),
72 'label' => $entity_type->getLabel(), 76 'label' => $entity_type->getLabel(),