From 6a6a2a34966a4413bd9ffa16c6033b6e660bb851 Mon Sep 17 00:00:00 2001 From: "Joaquin \"Florius\" Azcarate" Date: Sat, 2 Apr 2022 00:03:21 +0200 Subject: [PATCH] server: `drift_home` already has a default (#61) `||` on an exsiting string does nothing --- server/src/lib/get-database-path.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/server/src/lib/get-database-path.ts b/server/src/lib/get-database-path.ts index 118abcb8..7c53babe 100644 --- a/server/src/lib/get-database-path.ts +++ b/server/src/lib/get-database-path.ts @@ -7,8 +7,7 @@ import config from "./config" // This does *not* support `~other_user/tmp` => `/home/other_user/tmp`. function getDatabasePath() { const fileName = "drift.sqlite" - const databasePath = - `${config.drift_home}/${fileName}` || `~/.drift/${fileName}` + const databasePath = `${config.drift_home}/${fileName}` const home = os.homedir().replace("$", "$$$$") return path.resolve(databasePath.replace(/^~($|\/|\\)/, home + "$1"))