Skip to content
Snippets Groups Projects
Unverified Commit 1e05f804 authored by Lee Rowlands's avatar Lee Rowlands
Browse files

Issue #3248649 by alexpott:...

Issue #3248649 by alexpott: \Drupal\views\Plugin\views\display\PathPluginBase::alterRoutes() can become very slow on a site with lots of entities and JsonAPI
parent f8a197f5
No related branches found
No related tags found
No related merge requests found
...@@ -245,8 +245,8 @@ public function collectRoutes(RouteCollection $collection) { ...@@ -245,8 +245,8 @@ public function collectRoutes(RouteCollection $collection) {
* TRUE, when the view should override the given route. * TRUE, when the view should override the given route.
*/ */
protected function overrideApplies($view_path, Route $view_route, Route $route) { protected function overrideApplies($view_path, Route $view_route, Route $route) {
return $this->overrideAppliesPathAndMethod($view_path, $view_route, $route) return (!$route->hasRequirement('_format') || $route->getRequirement('_format') === 'html')
&& (!$route->hasRequirement('_format') || $route->getRequirement('_format') === 'html'); && $this->overrideAppliesPathAndMethod($view_path, $view_route, $route);
} }
/** /**
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment