From d9b4e6868059d007a5786612d26c1a11cc28a6cc Mon Sep 17 00:00:00 2001 From: Chris McCafferty Date: Wed, 26 Apr 2017 16:54:36 -0400 Subject: [PATCH] Issue #2868949 by bircher: LayoutPluginManager should use ContainerDerivativeDiscoveryDecorator --- core/lib/Drupal/Core/Layout/LayoutPluginManager.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/lib/Drupal/Core/Layout/LayoutPluginManager.php b/core/lib/Drupal/Core/Layout/LayoutPluginManager.php index e11f1055ba..0a2878572a 100644 --- a/core/lib/Drupal/Core/Layout/LayoutPluginManager.php +++ b/core/lib/Drupal/Core/Layout/LayoutPluginManager.php @@ -3,13 +3,13 @@ namespace Drupal\Core\Layout; use Drupal\Component\Annotation\Plugin\Discovery\AnnotationBridgeDecorator; -use Drupal\Component\Plugin\Discovery\DerivativeDiscoveryDecorator; use Drupal\Component\Plugin\Exception\InvalidPluginDefinitionException; use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Extension\ModuleHandlerInterface; use Drupal\Core\Extension\ThemeHandlerInterface; use Drupal\Core\Plugin\DefaultPluginManager; use Drupal\Core\Plugin\Discovery\AnnotatedClassDiscovery; +use Drupal\Core\Plugin\Discovery\ContainerDerivativeDiscoveryDecorator; use Drupal\Core\Plugin\Discovery\YamlDiscoveryDecorator; use Drupal\Core\Layout\Annotation\Layout; @@ -66,7 +66,7 @@ protected function getDiscovery() { $discovery = new AnnotatedClassDiscovery($this->subdir, $this->namespaces, $this->pluginDefinitionAnnotationName, $this->additionalAnnotationNamespaces); $discovery = new YamlDiscoveryDecorator($discovery, 'layouts', $this->moduleHandler->getModuleDirectories() + $this->themeHandler->getThemeDirectories()); $discovery = new AnnotationBridgeDecorator($discovery, $this->pluginDefinitionAnnotationName); - $discovery = new DerivativeDiscoveryDecorator($discovery); + $discovery = new ContainerDerivativeDiscoveryDecorator($discovery); $this->discovery = $discovery; } return $this->discovery; -- GitLab