mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-14 14:07:38 -07:00
Better error reporting
This commit is contained in:
parent
05d42b185d
commit
7d6a1e8ef6
1 changed files with 8 additions and 3 deletions
11
src/index.ts
11
src/index.ts
|
@ -194,7 +194,12 @@ cluster.on('exit', worker => {
|
|||
// Display detail of unhandled promise rejection
|
||||
process.on('unhandledRejection', console.dir);
|
||||
|
||||
// Dying away...
|
||||
process.on('exit', () => {
|
||||
Logger.info('The process is going exit');
|
||||
// Display detail of uncaught exception
|
||||
process.on('uncaughtException', err => {
|
||||
console.error(err);
|
||||
});
|
||||
|
||||
// Dying away...
|
||||
process.on('exit', code => {
|
||||
Logger.info(`The process is going exit (${code})`);
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue