mirror of
https://github.com/vrana/adminer.git
synced 2025-08-15 02:54:28 +02:00
Wrap connection error message
This commit is contained in:
@@ -166,7 +166,7 @@ if (isset($_GET["username"]) && is_string(get_password())) {
|
|||||||
|
|
||||||
$login = null;
|
$login = null;
|
||||||
if (!is_object($connection) || ($login = $adminer->login($_GET["username"], get_password())) !== true) {
|
if (!is_object($connection) || ($login = $adminer->login($_GET["username"], get_password())) !== true) {
|
||||||
$error = (is_string($connection) ? h($connection) : (is_string($login) ? $login : lang('Invalid credentials.')));
|
$error = (is_string($connection) ? nl_br(h($connection)) : (is_string($login) ? $login : lang('Invalid credentials.')));
|
||||||
auth_error($error . (preg_match('~^ | $~', get_password()) ? '<br>' . lang('There is a space in the input password which might be the cause.') : ''));
|
auth_error($error . (preg_match('~^ | $~', get_password()) ? '<br>' . lang('There is a space in the input password which might be the cause.') : ''));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user