Fix string.

This commit is contained in:
Stanislas Dolcini 2018-10-05 19:47:21 +02:00
parent b6a989599c
commit 59a95f7c01

View file

@ -149,10 +149,10 @@ class ConnectionHandler
setMsgLanguage($lang); setMsgLanguage($lang);
$domainName = $mysqli->escape_string($clientApplication); $domainName = $mysqli->escape_string($clientApplication);
if ($stmt = $mysqli->prepare("SELECT TOP 1 domain_id FROM domain WHERE domain_name='?'")) { if ($stmt = $mysqli->prepare('SELECT domain_id FROM domain WHERE domain_name=\'?\' LIMIT 1')) {
$stmt->bind_param("s", $domainName); $stmt->bind_param("s", $domainName);
$stmt->execute(); $stmt->execute();
$stmt->bind_result($result) or die(errorMsgBlock(3006, $query, 'main', $DBName, $DBHost, $DBUserName, mysqli_error($link))); $stmt->bind_result($result) or die(errorMsgBlock(3006, $query, 'main', $DBName, $DBHost, $DBUserName, $db_Connection->error));
$stmt->fetch(); $stmt->fetch();
if ($stmt->num_rows == 0) { if ($stmt->num_rows == 0) {
// unrecoverable error, we must giveup // unrecoverable error, we must giveup