mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-07 11:48:55 -05:00
... (#3350)
Signed-off-by: Drapersniper <27962761+drapersniper@users.noreply.github.com>
This commit is contained in:
parent
54711b2054
commit
ed76454ddb
1
changelog.d/audio/3349.bugfix.1.rst
Normal file
1
changelog.d/audio/3349.bugfix.1.rst
Normal file
@ -0,0 +1 @@
|
||||
Fixed a bug where ``[p]audioset dc`` didn't disconnect the bot.
|
||||
@ -535,17 +535,18 @@ class Audio(commands.Cog):
|
||||
player_check = await self._players_check()
|
||||
await self._status_check(*player_check)
|
||||
|
||||
if not autoplay and event_type == lavalink.LavalinkEvents.QUEUE_END and notify:
|
||||
notify_channel = player.fetch("channel")
|
||||
if notify_channel:
|
||||
notify_channel = self.bot.get_channel(notify_channel)
|
||||
await self._embed_msg(notify_channel, title=_("Queue Ended."))
|
||||
elif not autoplay and event_type == lavalink.LavalinkEvents.QUEUE_END and disconnect:
|
||||
self.bot.dispatch("red_audio_audio_disconnect", guild)
|
||||
await player.disconnect()
|
||||
if event_type == lavalink.LavalinkEvents.QUEUE_END and status:
|
||||
player_check = await self._players_check()
|
||||
await self._status_check(*player_check)
|
||||
if event_type == lavalink.LavalinkEvents.QUEUE_END:
|
||||
if not autoplay:
|
||||
notify_channel = player.fetch("channel")
|
||||
if notify_channel and notify:
|
||||
notify_channel = self.bot.get_channel(notify_channel)
|
||||
await self._embed_msg(notify_channel, title=_("Queue Ended."))
|
||||
if disconnect:
|
||||
self.bot.dispatch("red_audio_audio_disconnect", guild)
|
||||
await player.disconnect()
|
||||
if status:
|
||||
player_check = await self._players_check()
|
||||
await self._status_check(*player_check)
|
||||
|
||||
if event_type in [
|
||||
lavalink.LavalinkEvents.TRACK_EXCEPTION,
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user