mirror of
https://github.com/ajayyy/SponsorBlockServer.git
synced 2025-12-10 13:37:01 +03:00
Log stack for unhandled errors
This commit is contained in:
@@ -6,6 +6,10 @@ import { startAllCrons } from "./cronjob";
|
||||
import { getCommit } from "./utils/getCommit";
|
||||
|
||||
async function init() {
|
||||
process.on("unhandledRejection", (error: any) => {
|
||||
console.dir(error.stack);
|
||||
});
|
||||
|
||||
await initDb();
|
||||
(global as any).HEADCOMMIT = config.mode === "development" ? "development"
|
||||
: config.mode === "test" ? "test"
|
||||
|
||||
Reference in New Issue
Block a user