Updated to Drupal 8.5. Core Media not yet in use.
[yaffs-website] / web / modules / contrib / entity / src / Revision / RevisionableContentEntityBase.php
index a7ec15ee905eb4033ca76a52125a6ee60da42e88..f6dc11cb3f9adb64a4d35cb7c8c85708f0a6378f 100644 (file)
@@ -3,7 +3,6 @@
 namespace Drupal\entity\Revision;
 
 use Drupal\Core\Entity\RevisionableContentEntityBase as BaseRevisionableContentEntityBase;
-use Drupal\Core\Entity\ContentEntityBase;
 
 /**
  * Improves the url route handling of core's revisionable content entity base.
@@ -14,12 +13,8 @@ abstract class RevisionableContentEntityBase extends BaseRevisionableContentEnti
    * {@inheritdoc}
    */
   protected function urlRouteParameters($rel) {
-    $uri_route_parameters = [];
+    $uri_route_parameters = parent::urlRouteParameters($rel);
 
-    if ($rel != 'collection') {
-      // The entity ID is needed as a route parameter.
-      $uri_route_parameters[$this->getEntityTypeId()] = $this->id();
-    }
     if (strpos($this->getEntityType()->getLinkTemplate($rel), $this->getEntityTypeId() . '_revision') !== FALSE) {
       $uri_route_parameters[$this->getEntityTypeId() . '_revision'] = $this->getRevisionId();
     }