maybe this

This commit is contained in:
Loic Bersier 2018-12-09 02:13:28 +01:00
parent 346874ce31
commit 27d0e73ca6

View file

@ -66,7 +66,7 @@ module.exports = class ttsvcCommand extends Command {
voiceChannel.join().then(connection => { voiceChannel.join().then(connection => {
const dispatcher = connection.playStream('./ttsvc.mp3'); const dispatcher = connection.playStream('./ttsvc.mp3');
// End at then end of the audio stream // End at then end of the audio stream
dispatcher.on('end', () => setTimeout(function(){ dispatcher.on('finish', () => setTimeout(function(){
voiceChannel.leave(); voiceChannel.leave();
}, 2000)); }, 2000));
}); });