forked from Supositware/Haha-Yes
uncaughtException
This commit is contained in:
parent
7f0453b3a5
commit
b123ceb584
1 changed files with 16 additions and 0 deletions
16
event/listeners/uncaughtException.js
Normal file
16
event/listeners/uncaughtException.js
Normal file
|
@ -0,0 +1,16 @@
|
||||||
|
const { Listener } = require('discord-akairo');
|
||||||
|
|
||||||
|
class unhandledRejectionListener extends Listener {
|
||||||
|
constructor() {
|
||||||
|
super('uncaughtException', {
|
||||||
|
emitter: 'process',
|
||||||
|
event: 'uncaughtException'
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
|
async exec(error) {
|
||||||
|
return console.error(`\x1b[31mUncaughtException: ${error}\x1b[37m`);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
module.exports = unhandledRejectionListener;
|
Loading…
Reference in a new issue