fixed error in query_id check
Dieser Commit ist enthalten in:
Ursprung
14776b896a
Commit
62e5e7d102
|
@ -173,7 +173,7 @@ class DB_Sql extends DB_Sql_Abstract {
|
||||||
$this->Row = 0;
|
$this->Row = 0;
|
||||||
$this->Errno = $this->_getErrorNumber();
|
$this->Errno = $this->_getErrorNumber();
|
||||||
$this->Error = $this->_getErrorMessage();
|
$this->Error = $this->_getErrorMessage();
|
||||||
if (!is_resource($this->Query_ID)) {
|
if (!$this->Query_ID) {
|
||||||
$this->halt($sQuery);
|
$this->halt($sQuery);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -360,15 +360,14 @@ class DB_Sql extends DB_Sql_Abstract {
|
||||||
if (!empty($table)) {
|
if (!empty($table)) {
|
||||||
$this->connect();
|
$this->connect();
|
||||||
$id = mysqli_query($this->Link_ID, sprintf("SELECT * FROM `%s` LIMIT 1", $table));
|
$id = mysqli_query($this->Link_ID, sprintf("SELECT * FROM `%s` LIMIT 1", $table));
|
||||||
if (!is_resource($id)) {
|
if (!$id) {
|
||||||
$this->halt('Metadata query failed.');
|
$this->halt('Metadata query failed.');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
//var_dump($this->Query_ID);
|
//var_dump($this->Query_ID);
|
||||||
$id = $this->Query_ID;
|
$id = $this->Query_ID;
|
||||||
if (!$id instanceof mysqli_result) {
|
if (!$id) {
|
||||||
echo "back";
|
|
||||||
$this->halt('No query specified.');
|
$this->halt('No query specified.');
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
Laden…
In neuem Issue referenzieren