Merge pull request #6130 from aternatik/bug-6129
FIX #6129 : correct test on database connection
This commit is contained in:
commit
3fc8e2cf4c
@ -249,7 +249,7 @@ if (! $error) {
|
||||
if (! $db->connected) print $langs->trans("IfDatabaseNotExistsGoBackAndUncheckCreate").'<br><br>';
|
||||
print $langs->trans("ErrorGoBackAndCorrectParameters");
|
||||
$error++;
|
||||
} elseif ($db->error && (empty($db_create_database) && $db->connected)) {
|
||||
} elseif ($db->error && ! (! empty($db_create_database) && $db->connected)) {
|
||||
// Note: you may experience error here with message "No such file or directory" when mysql was installed for the first time but not yet launched.
|
||||
if ($db->error == "No such file or directory") print '<div class="error">'.$langs->trans("ErrorToConnectToMysqlCheckInstance").'</div>';
|
||||
else print '<div class="error">'.$db->error.'</div>';
|
||||
@ -991,4 +991,3 @@ function write_conf_file($conffile)
|
||||
|
||||
return $error;
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user