summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlex Pott2017-05-22 10:41:58 +0100
committerAlex Pott2017-05-22 10:41:58 +0100
commit16c5a8fa21936147c7bdc0e657b2dd82b39a7490 (patch)
tree404bd78fa2e02909142dbc298678bccf52ee0ea1
parentb5742e6890f28ae9c8021cebf94c2af5fb79a319 (diff)
Issue #2879959 by chr.fritsch: Media should extend EditorialContentEntityBase
-rw-r--r--core/modules/media/src/Entity/Media.php9
1 files changed, 2 insertions, 7 deletions
diff --git a/core/modules/media/src/Entity/Media.php b/core/modules/media/src/Entity/Media.php
index e73710d..8584041 100644
--- a/core/modules/media/src/Entity/Media.php
+++ b/core/modules/media/src/Entity/Media.php
@@ -2,14 +2,12 @@
namespace Drupal\media\Entity;
-use Drupal\Core\Entity\EntityPublishedTrait;
+use Drupal\Core\Entity\EditorialContentEntityBase;
use Drupal\Core\Entity\EntityStorageInterface;
use Drupal\Core\Entity\EntityTypeInterface;
-use Drupal\Core\Entity\RevisionableContentEntityBase;
use Drupal\Core\Field\BaseFieldDefinition;
use Drupal\Core\StringTranslation\StringTranslationTrait;
use Drupal\media\MediaInterface;
-use Drupal\Core\Entity\EntityChangedTrait;
use Drupal\media\MediaSourceEntityConstraintsInterface;
use Drupal\media\MediaSourceFieldConstraintsInterface;
use Drupal\user\UserInterface;
@@ -82,10 +80,8 @@ use Drupal\user\UserInterface;
* }
* )
*/
-class Media extends RevisionableContentEntityBase implements MediaInterface {
+class Media extends EditorialContentEntityBase implements MediaInterface {
- use EntityChangedTrait;
- use EntityPublishedTrait;
use StringTranslationTrait;
/**
@@ -367,7 +363,6 @@ class Media extends RevisionableContentEntityBase implements MediaInterface {
*/
public static function baseFieldDefinitions(EntityTypeInterface $entity_type) {
$fields = parent::baseFieldDefinitions($entity_type);
- $fields += static::publishedBaseFieldDefinitions($entity_type);
$fields['name'] = BaseFieldDefinition::create('string')
->setLabel(t('Name'))