install_verify_database_ready

install_verify_database_ready()

Verify that the database is ready (no existing Drupal installation).

File

core/includes/install.core.inc, line 1112
API functions for installing Drupal.

Code

1
2
3
4
5
6
7
8
9
10
11
function install_verify_database_ready() {
  $system_schema = system_schema();
  end($system_schema);
  $table = key($system_schema);
 
  if ($database = Database::getConnectionInfo()) {
    if (Database::getConnection()->schema()->tableExists($table)) {
      throw new AlreadyInstalledException(\Drupal::service('string_translation'));
    }
  }
}
doc_Drupal
2025-01-10 15:47:30
Comments
Leave a Comment

Please login to continue.