1
0
mirror of https://github.com/vrana/adminer.git synced 2025-08-13 01:54:00 +02:00

Move variable initialization

This commit is contained in:
Jakub Vrana
2025-03-08 21:45:21 +01:00
parent ad2cbbf26e
commit 862e5b4aa4
4 changed files with 8 additions and 10 deletions

View File

@@ -81,9 +81,8 @@ if ($_POST && !$error) {
. convert_fields($columns, $fields, $select)
. "\nFROM " . table($TABLE);
$group_by = ($group && $is_group ? "\nGROUP BY " . implode(", ", $group) : "") . ($order ? "\nORDER BY " . implode(", ", $order) : "");
if (!is_array($_POST["check"]) || $primary) {
$query = "SELECT $from$where_check$group_by";
} else {
$query = "SELECT $from$where_check$group_by";
if (is_array($_POST["check"]) && !$primary) {
$union = array();
foreach ($_POST["check"] as $val) {
// where is not unique so OR can't be used