From 152a4c77969ad63a465076679dd88468ec8d8d13 Mon Sep 17 00:00:00 2001 From: ayeuhugyu Date: Wed, 3 Jan 2024 16:56:14 -0800 Subject: [PATCH] fixed voiceStateUpdate --- src/events/voiceStateUpdate.js | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/events/voiceStateUpdate.js b/src/events/voiceStateUpdate.js index 62743b0..43544ac 100644 --- a/src/events/voiceStateUpdate.js +++ b/src/events/voiceStateUpdate.js @@ -14,7 +14,7 @@ export default async function (oldState, newState, client) { console.log(err); const debugchannel = client.channels.cache.get("1148814162273763418"); debugchannel.send( - "invalid voiceStateUpdate: no guild found. check console for details" + "invalid voiceStateUpdate: no guild found. check console for details <@440163494529073152>" ); return; } @@ -40,8 +40,9 @@ export default async function (oldState, newState, client) { ).size <= 1 ) { connection.destroy(); - console.log( - `destroyed voice connection for guild ${guild.id} in channel ${connection.joinConfig.channelId}` + const debugchannel = client.channels.cache.get("1148814162273763418"); + debugchannel.send( + `left <#${connection.joinConfig.channelId}>} due to nobody being in it` ); } }