mirror of
https://github.com/warengroup/eximiabots-radiox.git
synced 2024-12-23 01:13:17 +00:00
Added SIGTERM event
This commit is contained in:
parent
45b23722fa
commit
430e0f9e51
@ -76,6 +76,10 @@ class RadioClient extends Client {
|
||||
require(`${events}SIGINT`).execute(this);
|
||||
});
|
||||
|
||||
process.on('SIGTERM', () => {
|
||||
require(`${events}SIGTERM`).execute(this);
|
||||
});
|
||||
|
||||
this.on("error", error => {
|
||||
console.error(error);
|
||||
});
|
||||
|
6
src/client/events/SIGTERM.js
Normal file
6
src/client/events/SIGTERM.js
Normal file
@ -0,0 +1,6 @@
|
||||
module.exports = {
|
||||
name: 'SIGTERM',
|
||||
async execute(client) {
|
||||
process.emit('SIGINT');
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user