diff --git a/core/lib/Drupal/Core/Theme/Registry.php b/core/lib/Drupal/Core/Theme/Registry.php index 094780a10e..46be6b9b49 100644 --- a/core/lib/Drupal/Core/Theme/Registry.php +++ b/core/lib/Drupal/Core/Theme/Registry.php @@ -470,14 +470,12 @@ protected function processExtension(array &$cache, $name, $type, $theme, $path) } if (isset($cache[$hook]['includes'])) { - $result[$hook]['includes'] = $cache[$hook]['includes']; + throw new \Exception(); } // Load the includes, as they may contain preprocess functions. if (isset($info['includes'])) { - foreach ($info['includes'] as $include_file) { - include_once $this->root . '/' . $include_file; - } + throw new \Exception(); } // If the theme implementation defines a file, then also use the path