Skip to content

Commit

Permalink
[AFK] fix view
Browse files Browse the repository at this point in the history
  • Loading branch information
japandotorg committed Oct 20, 2023
1 parent 6aa2512 commit d1ef5a5
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions afk/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -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())
Expand Down Expand Up @@ -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):
Expand Down

0 comments on commit d1ef5a5

Please sign in to comment.