From 83fa9b4ad7940f26c6a5bd6f02155671d31ba02f Mon Sep 17 00:00:00 2001 From: AnxietyisReal <96593068+AnxietyisReal@users.noreply.github.com> Date: Sun, 25 Jun 2023 06:53:31 +1000 Subject: [PATCH] Let's pray this works --- src/index.ts | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/index.ts b/src/index.ts index 86f29a3..5e3320a 100644 --- a/src/index.ts +++ b/src/index.ts @@ -43,8 +43,7 @@ client.on('error', (error: Error)=>DZ(error, 'client-error')); // Audio Player event handling player.events.on('playerStart', (queue,track)=>queue.channel.send({embeds:[new client.embed().setColor(client.config.embedColor).setTitle(`${track.raw.title} - ${track.raw.author}`).setFooter({text:`Playing in ${queue.channel.name}`}).setThumbnail(track.raw.thumbnail)]})); player.events.on('playerFinish', (queue,track)=>{ - if (queue.tracks.size < 1) return queue.channel.send('There\'s no songs left in the queue, leaving voice channel in 15 seconds.'); - setTimeout(()=>queue.connection.disconnect(), 15000) + if (queue.tracks.size < 1) return queue.channel.send('There\'s no songs left in the queue, leaving voice channel in 15 seconds.').then(()=>setTimeout(()=>queue.connection.disconnect(), 15000)) }) player.events.on('audioTrackAdd', (queue,track)=>queue.channel.send({embeds:[new client.embed().setColor(client.config.embedColorGreen).setTitle(`${track.raw.title} - ${track.raw.author}`).setFooter({text:`Added to queue`}).setThumbnail(track.raw.thumbnail)]})); /* player.events.on('debug', (queue,message)=>{