1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-06 14:46:36 +02:00

Always return array from table_status()

This commit is contained in:
Jakub Vrana
2025-03-26 01:34:48 +01:00
parent cd207238b7
commit cccc784da4
19 changed files with 28 additions and 49 deletions

View File

@@ -127,7 +127,7 @@ ORDER BY ORDINAL_POSITION", null, "") as $row
$return[$row["TABLE_NAME"]]["keys"][$row["CONSTRAINT_NAME"]][$row["COLUMN_NAME"]] = $row["REFERENCED_COLUMN_NAME"];
}
foreach ($return as $key => $val) {
$name = $this->tableName(table_status($key, true));
$name = $this->tableName(table_status1($key, true));
if ($name != "") {
$search = preg_quote($tableName);
$separator = "(:|\\s*-)?\\s+";
@@ -660,7 +660,7 @@ ORDER BY ORDINAL_POSITION", null, "") as $row
if (list($target, $id, $name) = $this->_foreignColumn(column_foreign_keys($table), $column)) {
$return = &$this->values[$target];
if ($return === null) {
$table_status = table_status($target);
$table_status = table_status1($target);
$return = ($table_status["Rows"] > 1000 ? "" : array("" => "") + get_key_vals("SELECT $id, $name FROM " . table($target) . " ORDER BY 2"));
}
if (!$return && $value !== null) {