From d1ef5a59761670991312d35cd6de0f46bf40787f Mon Sep 17 00:00:00 2001 From: Lemon Rose Date: Sat, 21 Oct 2023 02:01:11 +0530 Subject: [PATCH] [AFK] fix view --- afk/views.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/afk/views.py b/afk/views.py index 897f5e43..05b2669f 100644 --- a/afk/views.py +++ b/afk/views.py @@ -54,7 +54,6 @@ class AFKView(discord.ui.View): def __init__(self, ctx: commands.Context, data: Dict, timeout: float = 60.0) -> None: super().__init__(timeout=timeout) self.ctx: commands.Context = ctx - self.cog: "AFK" = ctx.cog # type: ignore self.data: Dict = data self._message: Optional[discord.Message] = None self.add_item(CloseButton()) @@ -82,7 +81,7 @@ async def _callback(self, interaction: discord.Interaction[Red], _: discord.ui.B ephemeral=True, ) else: - await self.cog._ping_list(interaction, self.data) + await self.ctx.cog._ping_list(interaction, self.data) class ViewDisableOnTimeout(discord.ui.View):