Fix a PHP notice "Undefined index: pred_username"

Signed-off-by: William Desportes <williamdes@wdes.fr>
This commit is contained in:
William Desportes 2021-03-20 17:43:43 +01:00
parent 88aa819c07
commit 33d6b0cf3c
No known key found for this signature in database
GPG Key ID: 90A0EF1B8251A889

View File

@ -2677,7 +2677,10 @@ class Privileges
} }
$sql_query = ''; $sql_query = '';
if ($_POST['pred_username'] === 'any') { // Some reports where sent to the error reporting server with phpMyAdmin 5.1.0
// pred_username was reported to be not defined
$predUsername = $_POST['pred_username'] ?? '';
if ($predUsername === 'any') {
$username = ''; $username = '';
} }
switch ($_POST['pred_hostname']) { switch ($_POST['pred_hostname']) {