Added error handeling
This commit is contained in:
parent
150b08fe4b
commit
de17681b28
1 changed files with 7 additions and 2 deletions
|
@ -46,6 +46,11 @@ class playCommand extends Command {
|
|||
voiceChannel.leave();
|
||||
return message.channel.send('Music ended, i left the channel');
|
||||
});
|
||||
})
|
||||
.catch(err => {
|
||||
console.error(err);
|
||||
voiceChannel.leave();
|
||||
return message.channel.send('An error has occured! is the link you sent valid?');
|
||||
});
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue