mirror of
https://github.com/vrana/adminer.git
synced 2025-08-06 22:56:46 +02:00
Add helper for $connection2
This commit is contained in:
@@ -270,9 +270,7 @@ if (isset($_GET["sqlite"])) {
|
||||
}
|
||||
|
||||
function indexes($table, $connection2 = null) {
|
||||
if (!is_object($connection2)) {
|
||||
$connection2 = connection();
|
||||
}
|
||||
$connection2 = connection($connection2);
|
||||
$return = array();
|
||||
$sql = get_val("SELECT sql FROM sqlite_master WHERE type = 'table' AND name = " . q($table), 0, $connection2);
|
||||
if (preg_match('~\bPRIMARY\s+KEY\s*\((([^)"]+|"[^"]*"|`[^`]*`)++)~i', $sql, $match)) {
|
||||
|
Reference in New Issue
Block a user