diff --git a/core/includes/install.core.inc b/core/includes/install.core.inc index 98c1ed9291d5e976b2a854cde6b1b3f7b52e3940..c608052cfb6e50af3c1927b2149a0423adbb092f 100644 --- a/core/includes/install.core.inc +++ b/core/includes/install.core.inc @@ -424,8 +424,11 @@ function install_begin_request($class_loader, &$install_state) { } $GLOBALS['conf']['container_service_providers']['InstallerConfigOverride'] = 'Drupal\Core\Installer\ConfigOverride'; - // Only allow dumping the container once the hash salt has been created. - $kernel = InstallerKernel::createFromRequest($request, $class_loader, $environment, (bool) Settings::get('hash_salt', FALSE)); + // Only allow dumping the container once the hash salt has been created. Note, + // InstallerKernel::createFromRequest() is not used because Settings is + // already initialized. + $kernel = new InstallerKernel($environment, $class_loader, (bool) Settings::get('hash_salt', FALSE)); + $kernel::bootEnvironment(); $kernel->setSitePath($site_path); $kernel->boot(); $container = $kernel->getContainer(); diff --git a/core/lib/Drupal/Core/Installer/InstallerKernel.php b/core/lib/Drupal/Core/Installer/InstallerKernel.php index eefeffe6ed9b5166fda28eef79d9f9424142f22b..adeb5c53eed62b1935dcd43c079b8d10a6abbe45 100644 --- a/core/lib/Drupal/Core/Installer/InstallerKernel.php +++ b/core/lib/Drupal/Core/Installer/InstallerKernel.php @@ -3,7 +3,6 @@ namespace Drupal\Core\Installer; use Drupal\Core\DrupalKernel; -use Symfony\Component\HttpFoundation\Request; /** * Extend DrupalKernel to handle force some kernel behaviors. @@ -67,15 +66,4 @@ public function getInstallProfile() { return $profile; } - /** - * {@inheritdoc} - */ - public static function createFromRequest(Request $request, $class_loader, $environment, $allow_dumping = TRUE, $app_root = NULL) { - // This override exists because we don't need to initialize the settings - // again as they already are in install_begin_request(). - $kernel = new static($environment, $class_loader, $allow_dumping, $app_root); - static::bootEnvironment($app_root); - return $kernel; - } - }