diff --git a/core/modules/views/src/Plugin/views/display/PathPluginBase.php b/core/modules/views/src/Plugin/views/display/PathPluginBase.php index d2f2b6e..0ca1429 100644 --- a/core/modules/views/src/Plugin/views/display/PathPluginBase.php +++ b/core/modules/views/src/Plugin/views/display/PathPluginBase.php @@ -521,6 +521,7 @@ public function postSaveView(array $original_display) { // An empty original display means a new view, we need a router rebuild. $route_rebuild = empty($original_display); + $this->display += ['display_options' => []]; $this->display['display_options'] += [ 'path' => '', 'route_name' => '', @@ -528,6 +529,7 @@ public function postSaveView(array $original_display) { 'access' => [], ]; + $original_display += ['display_options' => []]; $original_display['display_options'] += [ 'path' => '', 'route_name' => '', diff --git a/core/modules/views/src/Views.php b/core/modules/views/src/Views.php index c736135..b2dd31e 100644 --- a/core/modules/views/src/Views.php +++ b/core/modules/views/src/Views.php @@ -540,7 +540,7 @@ protected static function t($string, array $args = array(), array $options = arr */ public static function routeRebuildNeeded() { // Set the router as needed to be rebuilt. - \Drupal::service('router.builder_indicator')->setRebuildNeeded(); + \Drupal::service('router.builder')->setRebuildNeeded(); // Reset the RouteSubscriber from views. \Drupal::getContainer()->get('views.route_subscriber')->reset();