diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/style/StylePluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/style/StylePluginBase.php
index 5585ca3..fe89adf 100644
--- a/core/modules/views/lib/Drupal/views/Plugin/views/style/StylePluginBase.php
+++ b/core/modules/views/lib/Drupal/views/Plugin/views/style/StylePluginBase.php
@@ -402,6 +402,17 @@ function pre_render($result) {
   }
 
   /**
+   * Renders a single view of a grouped content.
+   */
+  protected function renderSingle(array $rows = array()) {
+    return array(
+      '#theme' => $this->themeFunctions(),
+      '#view' => $this->view,
+      '#rows' => $rows,
+    );
+  }
+
+  /**
    * Render the display in this style.
    */
   function render() {
@@ -461,14 +472,10 @@ function render_grouping_sets($sets, $level = 0) {
           }
         }
 
-        $output[] = array(
-          '#theme' => $this->themeFunctions(),
-          '#view' => $this->view,
-          '#options' => $this->options,
-          '#grouping_level' => $level,
-          '#rows' => $set['rows'],
-          '#title' => $set['group'],
-        );
+        $single_output = $this->renderSingle($set['rows']);
+        $single_output['#grouping_level'] = $level;
+        $single_output['#title'] = $set['group'];
+        $output[] = $single_output;
       }
     }
     unset($this->view->row_index);
