Skip to content

Commit 06bc47b

Browse files
committed
fix: End process if db didn't connect
1 parent d224e9c commit 06bc47b

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

src/models/db.ts

+1
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ knex.raw("SELECT 'test connection';").then(() => {
1010
logger.info(database.connectionSuccess);
1111
}).catch((err) => {
1212
logger.error(database.connectionFailure);
13+
process.exit(1);
1314
throw err;
1415
});
1516

0 commit comments

Comments
 (0)