mirror of
https://github.com/ChomeNS/chomens-bot-mc.git
synced 2024-11-23 07:38:00 -05:00
move uncaught to index
This commit is contained in:
parent
eb4e07b8cc
commit
a0e6c90ef3
2 changed files with 4 additions and 6 deletions
6
bot.js
6
bot.js
|
@ -184,12 +184,6 @@ async function createBot(server, config, getBots, dcclient) {
|
|||
|
||||
bot._client.on('error', function() {});
|
||||
|
||||
process.once('uncaughtException', (error) => {
|
||||
console.error('uncaught ' + util.inspect(error));
|
||||
// channel.send('uncaught ```\n' + util.inspect(error) + '\n```');
|
||||
// bot.emit('end', 'uncaughtException', 'process: uncaughtException');
|
||||
});
|
||||
|
||||
return bot;
|
||||
};
|
||||
|
||||
|
|
4
index.js
4
index.js
|
@ -29,3 +29,7 @@ dcclient.on('ready', () => {
|
|||
});
|
||||
|
||||
dcclient.login(config.discord.token);
|
||||
|
||||
process.on('uncaughtException', (error) => {
|
||||
console.log(error);
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue