diff --git a/src/Database/Database.php b/src/Database/Database.php index 920392a0f3..88d8d7d0f6 100644 --- a/src/Database/Database.php +++ b/src/Database/Database.php @@ -136,11 +136,11 @@ class Database $connect .= ";charset=" . $charset; } - if ($socket) { - $connect .= ";$unix_socket=" . $socket; - } + if ($socket) { + $connect .= ";$unix_socket=" . $socket; + } - try { + try { $this->connection = @new PDO($connect, $user, $pass, [PDO::ATTR_PERSISTENT => $persistent]); $this->connection->setAttribute(PDO::ATTR_EMULATE_PREPARES, $this->pdo_emulate_prepares); $this->connection->setAttribute(PDO::ATTR_ERRMODE, PDO::ERRMODE_SILENT);