diff --git a/musicbot/cogs/music/voice_client.py b/musicbot/cogs/music/voice_client.py index cfdaf73..52f1855 100644 --- a/musicbot/cogs/music/voice_client.py +++ b/musicbot/cogs/music/voice_client.py @@ -7,10 +7,13 @@ from musicbot.cogs.music.music_errors import MusicError class BasicVoiceClient(discord.VoiceClient): def __init__(self, client: MusicBot, channel: discord.VoiceChannel): - self.music_bot = client + # Needs to be named client in order for base class to work + # in most cases lavalink handles disconnects, but if we force it then we'll get an error. + # during self.cleanup() + self.client = client self.channel = channel - if self.music_bot.lavalink: - self.lavalink = self.music_bot.lavalink + if self.client.lavalink: + self.lavalink = self.client.lavalink else: raise MusicError("client did not have defined lavalink before connect") diff --git a/musicbot/utils/userinteraction/scroller.py b/musicbot/utils/userinteraction/scroller.py index 3d1eec7..2fd84ba 100644 --- a/musicbot/utils/userinteraction/scroller.py +++ b/musicbot/utils/userinteraction/scroller.py @@ -105,7 +105,7 @@ class Scroller: await self.scrolling_done.wait() return self.message - def update_view_on_interaction(self, interaction: discord.Interaction): + def update_view_on_interaction(self, _: discord.Interaction): self.update_view() def update_view(self):