diff --git a/core/modules/views/lib/Drupal/views/Tests/Plugin/StyleMappingTest.php b/core/modules/views/lib/Drupal/views/Tests/Plugin/StyleMappingTest.php index f745a08..a376b42 100644 --- a/core/modules/views/lib/Drupal/views/Tests/Plugin/StyleMappingTest.php +++ b/core/modules/views/lib/Drupal/views/Tests/Plugin/StyleMappingTest.php @@ -56,6 +56,7 @@ public function testMappedOutput() { protected function mappedOutputHelper($view) { $rendered_output = $view->preview(); $this->storeViewPreview($rendered_output); + debug($rendered_output); $rows = $this->elements->body->div->div->div; $data_set = $this->dataSet(); diff --git a/core/modules/views/lib/Drupal/views/ViewExecutable.php b/core/modules/views/lib/Drupal/views/ViewExecutable.php index f590faa..6fb8c02 100644 --- a/core/modules/views/lib/Drupal/views/ViewExecutable.php +++ b/core/modules/views/lib/Drupal/views/ViewExecutable.php @@ -687,15 +687,12 @@ public function initStyle() { return is_object($this->style_plugin); } - $style = $this->display_handler->getOption('style'); - $this->style_plugin = Views::pluginManager('style')->createInstance($style['type']); + $this->style_plugin = $this->display_handler->getPlugin('style'); if (empty($this->style_plugin)) { return FALSE; } - // Init the new style handler with data. - $this->style_plugin->init($this, $this->display_handler); return TRUE; }