From 749fa4bb95aea4c48c5d219fe9674872cded9107 Mon Sep 17 00:00:00 2001 From: Ajay Date: Tue, 14 Jun 2022 16:22:59 -0400 Subject: [PATCH] Fix not all db config vars being used --- src/databases/databases.ts | 12 +++--------- 1 file changed, 3 insertions(+), 9 deletions(-) diff --git a/src/databases/databases.ts b/src/databases/databases.ts index 52f357c..4bea8c7 100644 --- a/src/databases/databases.ts +++ b/src/databases/databases.ts @@ -17,11 +17,8 @@ if (config.mysql) { readOnly: config.readOnly, createDbIfNotExists: config.createDatabaseIfNotExist, postgres: { - user: config.postgres?.user, - host: config.postgres?.host, + ...config.postgres, database: "sponsorTimes", - password: config.postgres?.password, - port: config.postgres?.port, } }); @@ -32,11 +29,8 @@ if (config.mysql) { readOnly: config.readOnly, createDbIfNotExists: config.createDatabaseIfNotExist, postgres: { - user: config.postgres?.user, - host: config.postgres?.host, - database: "privateDB", - password: config.postgres?.password, - port: config.postgres?.port, + ...config.postgres, + database: "privateDB" } }); } else {