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

PostgreSQL: Unuse deleted fetch_field

This commit is contained in:
Jakub Vrana
2025-03-27 18:46:46 +01:00
parent b23bf6c055
commit a2ff6a7fb1
2 changed files with 3 additions and 2 deletions

View File

@@ -758,7 +758,8 @@ ORDER BY SPECIFIC_NAME');
} }
function last_id($result) { function last_id($result) {
return (is_object($result) && $result->num_rows ? $result->fetch_column(0) : 0); $row = (is_object($result) ? $result->fetch_row() : array());
return ($row ? $row[0] : 0);
} }
function explain($connection, $query) { function explain($connection, $query) {

View File

@@ -77,7 +77,7 @@ function put_file($match) {
} }
} }
} }
unset($functions["__construct"], $functions["__destruct"], $functions["set_charset"], $functions["fetch_column"]); unset($functions["__construct"], $functions["__destruct"], $functions["set_charset"]);
foreach ($functions as $val) { foreach ($functions as $val) {
if (!strpos($return, "$val(")) { if (!strpos($return, "$val(")) {
fprintf(STDERR, "Missing $val in $vendor\n"); fprintf(STDERR, "Missing $val in $vendor\n");