We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5724968 commit a0005ecCopy full SHA for a0005ec
src/FakePdoTrait.php
@@ -52,7 +52,7 @@ public function __construct(string $dsn, string $username = '', string $passwd =
52
$dsn = \Nyholm\Dsn\DsnParser::parse($dsn);
53
$host = $dsn->getHost();
54
55
- if (preg_match('/dbname=([a-zA-Z0-9_]+);/', $host, $matches)) {
+ if (preg_match('/dbname=([a-zA-Z0-9_]+)(?:;|$)/', $host, $matches)) {
56
$this->databaseName = $matches[1];
57
}
58
0 commit comments