Commit eb0a4615 authored by Benjamin Eberlei's avatar Benjamin Eberlei

Merge branch 'DBAL-137' into 2.1.x

parents 0127ee98 a702b6b6
...@@ -56,7 +56,7 @@ class Driver implements \Doctrine\DBAL\Driver ...@@ -56,7 +56,7 @@ class Driver implements \Doctrine\DBAL\Driver
private function _constructPdoDsn(array $params) private function _constructPdoDsn(array $params)
{ {
$dsn = 'mysql:'; $dsn = 'mysql:';
if (isset($params['host'])) { if (isset($params['host']) && $params['host'] != '') {
$dsn .= 'host=' . $params['host'] . ';'; $dsn .= 'host=' . $params['host'] . ';';
} }
if (isset($params['port'])) { if (isset($params['port'])) {
......
...@@ -34,7 +34,7 @@ class Driver implements \Doctrine\DBAL\Driver ...@@ -34,7 +34,7 @@ class Driver implements \Doctrine\DBAL\Driver
private function _constructPdoDsn(array $params) private function _constructPdoDsn(array $params)
{ {
$dsn = 'pgsql:'; $dsn = 'pgsql:';
if (isset($params['host'])) { if (isset($params['host']) && $params['host'] != '') {
$dsn .= 'host=' . $params['host'] . ' '; $dsn .= 'host=' . $params['host'] . ' ';
} }
if (isset($params['port'])) { if (isset($params['port'])) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment