diff options
author | TheArcaneBrony <myrainbowdash949@gmail.com> | 2023-01-31 23:27:19 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-01-31 23:27:19 +0100 |
commit | f7c0317c8d3f19b0a4600eec2fcee504920fa055 (patch) | |
tree | 07fca893a4b67e03984b76bdd8b40f42c4eaf3f5 | |
parent | Fix missing capitalisation in database connected log (diff) | |
download | server-f7c0317c8d3f19b0a4600eec2fcee504920fa055.tar.xz |
Hotfix postgres connection string to not silently fail migrations
-rw-r--r-- | src/util/util/Database.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/util/util/Database.ts b/src/util/util/Database.ts index 927d6428..31dfa710 100644 --- a/src/util/util/Database.ts +++ b/src/util/util/Database.ts @@ -36,7 +36,7 @@ const dbConnectionString = process.env.DATABASE || path.join(process.cwd(), "database.db"); const DatabaseType = dbConnectionString.includes("://") - ? dbConnectionString.split(":")[0]?.replace("+srv", "") + ? dbConnectionString.split(":")[0]?.replace("+srv", "")?.replace("postgres", "postgresql") : "sqlite"; const isSqlite = DatabaseType.includes("sqlite"); |