From ab7fe3e828300b719ccc0af6cf9edf5d2be3d3f0 Mon Sep 17 00:00:00 2001 From: Rafael Bradley Date: Sun, 16 Mar 2025 11:12:42 -0300 Subject: [PATCH] feat(shard): :sparkles: Notify users when Payphone doesn't have permissions to read message history. --- payphone/cogs/calls/cog.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/payphone/cogs/calls/cog.py b/payphone/cogs/calls/cog.py index b396608..510c6e6 100644 --- a/payphone/cogs/calls/cog.py +++ b/payphone/cogs/calls/cog.py @@ -293,6 +293,13 @@ class Calls(base.Cog): except discord.errors.NotFound: replied_message = None + except discord.errors.Forbidden: + replied_message = None + + await self.bot.get_partial_messageable(other_channel).send( + "❌ **Payphone** is missing permissions to read messages from this channel. Make sure it's got `Read Message History` permissions." + ) + if replied_message is not None: replied_message_content = self.bot.clean_message(replied_message) replied_participant = await call.get_participant(