From 0808640ec0d346a427cf87a07a8dc8317bfff0c1 Mon Sep 17 00:00:00 2001 From: Mononaut Date: Sun, 1 Oct 2023 16:38:45 +0100 Subject: [PATCH] Check database enabled before releasing PID lock file --- backend/src/index.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/backend/src/index.ts b/backend/src/index.ts index a8af35d1c..e7e1afa3d 100644 --- a/backend/src/index.ts +++ b/backend/src/index.ts @@ -315,7 +315,9 @@ class Server { } onExit(exitEvent): void { - DB.releasePidLock(); + if (config.DATABASE.ENABLED) { + DB.releasePidLock(); + } process.exit(0); } }