Commit 04037a50 authored by Dries's avatar Dries
Browse files

- Patch #92923 by webchick: made the installer more robust to missing modules.

parent 342f95d4
......@@ -73,8 +73,13 @@ function install_main() {
install_change_settings($profile, $install_locale);
}
// Perform actual installation defined in the profile.
// Verify existence of all required modules.
$modules = drupal_verify_profile($profile, $install_locale);
if (!$modules) {
install_missing_modules_error($profile);
}
// Perform actual installation defined in the profile.
drupal_install_profile($profile, $modules);
// Warn about settings.php permissions risk
......@@ -498,6 +503,18 @@ function install_already_done_error() {
exit;
}
/**
* Show an error page when Drupal is missing required modules.
*/
function install_missing_modules_error($profile) {
global $base_url;
drupal_maintenance_theme();
drupal_set_title(st('Modules missing'));
print theme('install_page', '<p>'. st('One or more required modules are missing. Please check the error messages and <a href="!url">try again</a>.', array('!url' => "install.php?profile=$profile")) .'</p>');
exit;
}
/**
* Page displayed when the installation is complete. Called from install.php.
*/
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment