aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMichael McVady <femtonaut@gmail.com>2023-07-08 13:41:09 -0500
committerMichael McVady <femtonaut@gmail.com>2023-07-08 13:41:09 -0500
commit26be9c37aaee44f31a852da46b07032577db6fc8 (patch)
tree9528ad4b7f86f9e8c194e8f26ef99cf9161af72c /src
parent27e88a9609277e0c76b73b1498d6262927deadf7 (diff)
Squash db connection bug
Diffstat (limited to 'src')
-rw-r--r--src/init.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/init.c b/src/init.c
index ea3daf3..2c1da6f 100644
--- a/src/init.c
+++ b/src/init.c
@@ -57,9 +57,9 @@ int init_db(void) {
if (env)
kore_buf_appendf(pg_config_buf, "password=%s ", env);
- env = getenv("POSTGRES_DBNAME");
+ env = getenv("POSTGRES_DB");
if (env)
- kore_buf_appendf(pg_config_buf, "user=%s ", env);
+ kore_buf_appendf(pg_config_buf, "dbname=%s ", env);
else
kore_buf_append(pg_config_buf, dbname, strlen(dbname));