Skip to content

Commit 3a74556

Browse files
committed
Do not send empty SELECT statement when no database has been given
1 parent 17ab4ad commit 3a74556

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/Factory.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ private function getDatabaseFromTarget($target)
135135
{
136136
$db = null;
137137
$path = parse_url($target, PHP_URL_PATH);
138-
if ($path !== null) {
138+
if ($path !== null && $path !== '') {
139139
// skip first slash
140140
$db = substr($path, 1);
141141
}

0 commit comments

Comments
 (0)