mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-11-21 18:27:59 -05:00
Discord.py dep update 3.1 (#2587)
* Dependency update discord.py==1.0.1 websockets<7 [style] black==19.3b0 [Docs] jinja==2.10.1 urllib3==1.24.2 Changes related to breaking changes from discord.py have also been made to match As of this commit, help formatter is back to discord.py's default
This commit is contained in:
@@ -3493,6 +3493,7 @@ class Audio(commands.Cog):
|
||||
)
|
||||
return r
|
||||
|
||||
@commands.Cog.listener()
|
||||
async def on_voice_state_update(self, member, before, after):
|
||||
if after.channel != before.channel:
|
||||
try:
|
||||
@@ -3500,7 +3501,7 @@ class Audio(commands.Cog):
|
||||
except (ValueError, KeyError, AttributeError):
|
||||
pass
|
||||
|
||||
def __unload(self):
|
||||
def cog_unload(self):
|
||||
if not self._cleaned_up:
|
||||
self.session.detach()
|
||||
|
||||
@@ -3515,8 +3516,9 @@ class Audio(commands.Cog):
|
||||
shutdown_lavalink_server()
|
||||
self._cleaned_up = True
|
||||
|
||||
__del__ = __unload
|
||||
__del__ = cog_unload
|
||||
|
||||
@commands.Cog.listener()
|
||||
async def on_guild_remove(self, guild: discord.Guild):
|
||||
"""
|
||||
This is to clean up players when
|
||||
|
||||
Reference in New Issue
Block a user