diff --git a/core/includes/update.inc b/core/includes/update.inc index c628d3f..bae7961 100644 --- a/core/includes/update.inc +++ b/core/includes/update.inc @@ -200,54 +200,17 @@ function update_prepare_d8_bootstrap() { exit; } - // During the bootstrap to DRUPAL_BOOTSTRAP_PAGE_CACHE, code will try to read - // the cache but the cache tables are not compatible yet. Use the Null backend - // by default to avoid exceptions. - $settings = settings()->getAll(); - $settings['cache']['default'] = 'cache.backend.memory'; - new Settings($settings); - // Enable UpdateServiceProvider service overrides. // @see update_flush_all_caches() $GLOBALS['conf']['container_service_providers']['UpdateServiceProvider'] = 'Drupal\Core\DependencyInjection\UpdateServiceProvider'; $GLOBALS['conf']['update_service_provider_overrides'] = TRUE; - // Check whether settings.php needs to be rewritten. - $settings_exist = !empty($GLOBALS['config_directories']); - - if (!$settings_exist || !is_dir(config_get_config_directory('active')) || !is_dir(config_get_config_directory('staging'))) { - drupal_install_config_directories(); - } - - // Bootstrap the kernel. - // Do not attempt to dump and write it. - $kernel = new DrupalKernel('update', drupal_classloader(), FALSE); - $kernel->boot(); - // module.inc is not yet loaded but there are calls to module_config_sort() // below. require_once __DIR__ . '/module.inc'; - // Moves install_profile from variable to settings. You can't do that in - // system.install because _system_rebuild_module_data() needs the profile - // directly. Check that it has not been set already. This is the case for - // Simpletest upgrade path tests. - if (!settings()->get('install_profile')) { - $old_variable = unserialize(\Drupal::database()->query('SELECT value FROM {variable} WHERE name = :name', array(':name' => 'install_profile'))->fetchField()); - $settings = array( - 'settings' => array( - 'install_profile' => (object) array( - 'value' => $old_variable, - 'required' => TRUE, - ), - ) - ); - drupal_rewrite_settings($settings); - } - // Now remove the cache override. $settings = settings()->getAll(); - unset($settings['cache']['default']); new Settings($settings); $kernel = new DrupalKernel('update', drupal_classloader(), FALSE); $kernel->boot();