diff options
author | 2022-12-26 13:04:18 +0100 | |
---|---|---|
committer | 2023-02-19 14:42:20 +0100 | |
commit | 74e2ba8b3f661cd09a072877cc8ec017c24098d7 (patch) | |
tree | bee46276e4c6ab988de166f657bf8776090904d9 | |
parent | use existing `build_error_embed` func to construct unauthorized message (diff) |
fix `AttributeError` on interaction.channel
This bus was introduced upon refactoring the perms check, and it calls channel from within a channel.
-rw-r--r-- | bot/exts/utilities/bookmark.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/bot/exts/utilities/bookmark.py b/bot/exts/utilities/bookmark.py index c856d80c..47db9a0b 100644 --- a/bot/exts/utilities/bookmark.py +++ b/bot/exts/utilities/bookmark.py @@ -136,7 +136,7 @@ class Bookmark(commands.Cog): async def _bookmark_context_menu_callback(self, interaction: discord.Interaction, message: discord.Message) -> None: """The callback that will be invoked upon using the bookmark's context menu command.""" - permissions = interaction.channel.channel.permissions_for(interaction.user) + permissions = interaction.channel.permissions_for(interaction.user) if not permissions.read_messages: log.info(f"{interaction.user.author} tried to bookmark a message in #{interaction.channel}" f"but has no permissions.") |