daily changes
This commit is contained in:
parent
5d910a62a1
commit
bf03a2e9af
@ -89,7 +89,6 @@ namespace Kasbot.Services
|
||||
IVoiceChannel channel = (Context.User as IVoiceState).VoiceChannel;
|
||||
|
||||
var audioClient = await channel.ConnectAsync();
|
||||
audioClient.ClientDisconnected += (id) => AudioClient_ClientDisconnected(Context.Guild.Id);
|
||||
audioClient.Disconnected += (ex) => AudioClient_ClientDisconnected(Context.Guild.Id);
|
||||
|
||||
conn = CreateConnection(audioClient, Context.Guild.Id);
|
||||
@ -112,7 +111,7 @@ namespace Kasbot.Services
|
||||
|
||||
if (nextMedia == null)
|
||||
{
|
||||
Clients[guildId].Queue.Dequeue();
|
||||
Clients[guildId].Queue.Clear();
|
||||
await Stop(guildId);
|
||||
return;
|
||||
}
|
||||
@ -242,17 +241,12 @@ namespace Kasbot.Services
|
||||
|
||||
private async Task RemoveMediaMessages(Media media)
|
||||
{
|
||||
try
|
||||
{
|
||||
if (media.Message != null)
|
||||
await media.Message.DeleteAsync();
|
||||
}
|
||||
catch { }
|
||||
try
|
||||
{
|
||||
if (media.PlayMessage != null)
|
||||
await media.PlayMessage.DeleteAsync();
|
||||
} catch { }
|
||||
}
|
||||
catch { }
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user