diff --git a/core/lib/Drupal/Core/Entity/Routing/EntityRouteProviderInterface.php b/core/lib/Drupal/Core/Entity/Routing/EntityRouteProviderInterface.php index 7d07cd6..a7daa94 100644 --- a/core/lib/Drupal/Core/Entity/Routing/EntityRouteProviderInterface.php +++ b/core/lib/Drupal/Core/Entity/Routing/EntityRouteProviderInterface.php @@ -24,6 +24,6 @@ * Returns a route collection or an array of routes keyed by name, like * route_callbacks inside 'routing.yml' files. */ - public function routes(EntityTypeInterface $entity_type); + public function getRoutes(EntityTypeInterface $entity_type); } diff --git a/core/lib/Drupal/Core/EventSubscriber/EntityRouteProviderSubscriber.php b/core/lib/Drupal/Core/EventSubscriber/EntityRouteProviderSubscriber.php index ff1b4b3..cc791bf 100644 --- a/core/lib/Drupal/Core/EventSubscriber/EntityRouteProviderSubscriber.php +++ b/core/lib/Drupal/Core/EventSubscriber/EntityRouteProviderSubscriber.php @@ -48,7 +48,7 @@ public function onDynamic(RouteBuildEvent $event) { foreach ($this->entityManager->getRouteProviders($entity_type->id()) as $route_provider) { // Allow to both return an array of routes or a route collection, // like route_callbacks in the routing.yml file. - $routes = $route_provider->routes($entity_type); + $routes = $route_provider->getRoutes($entity_type); if ($routes instanceof RouteCollection) { $route_collection->addCollection($routes); } diff --git a/core/modules/node/src/Entity/NodeRouteProvider.php b/core/modules/node/src/Entity/NodeRouteProvider.php index a39b925..fa1c02d 100644 --- a/core/modules/node/src/Entity/NodeRouteProvider.php +++ b/core/modules/node/src/Entity/NodeRouteProvider.php @@ -20,7 +20,7 @@ class NodeRouteProvider implements EntityRouteProviderInterface { /** * {@inheritdoc} */ - public function routes( EntityTypeInterface $entity_type) { + public function getRoutes( EntityTypeInterface $entity_type) { $route_collection = new RouteCollection(); $route = (new Route('/node/{node}')) ->addDefaults([ diff --git a/core/modules/user/src/Entity/UserRouteProvider.php b/core/modules/user/src/Entity/UserRouteProvider.php index abeaeb1..f4cfd79 100644 --- a/core/modules/user/src/Entity/UserRouteProvider.php +++ b/core/modules/user/src/Entity/UserRouteProvider.php @@ -20,7 +20,7 @@ class UserRouteProvider implements EntityRouteProviderInterface { /** * {@inheritdoc} */ - public function routes(EntityTypeInterface $entity_type) { + public function getRoutes(EntityTypeInterface $entity_type) { $route_collection = new RouteCollection(); $route = (new Route('/user/{user}')) ->setDefaults([