mirror of
https://git.tt-rss.org/git/tt-rss.git
synced 2025-12-13 22:35:55 +00:00
allow connections to pgsql without password
This commit is contained in:
6
db.php
6
db.php
@@ -5,7 +5,11 @@ require_once "config.php";
|
|||||||
function db_connect($host, $user, $pass, $db) {
|
function db_connect($host, $user, $pass, $db) {
|
||||||
if (DB_TYPE == "pgsql") {
|
if (DB_TYPE == "pgsql") {
|
||||||
|
|
||||||
$string = "dbname=$db user=$user password=$pass";
|
$string = "dbname=$db user=$user";
|
||||||
|
|
||||||
|
if ($pass) {
|
||||||
|
$string .= " password=$pass";
|
||||||
|
}
|
||||||
|
|
||||||
if ($host) {
|
if ($host) {
|
||||||
$string .= " host=$host";
|
$string .= " host=$host";
|
||||||
|
|||||||
Reference in New Issue
Block a user