From 216809fb56b95850ae4ec32bcf9764f4a0a7913f Mon Sep 17 00:00:00 2001 From: Fixator10 Date: Mon, 12 Apr 2021 20:11:45 +0400 Subject: [PATCH] [ChatChart] add check for send_messages for trigger_typing (#225) *again* --- chatchart/chatchart.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/chatchart/chatchart.py b/chatchart/chatchart.py index 3decdec..04450c5 100644 --- a/chatchart/chatchart.py +++ b/chatchart/chatchart.py @@ -156,7 +156,8 @@ class Chatchart(commands.Cog): description=f"This might take a while...\n{history_counter}/{messages} messages gathered", colour=await self.bot.get_embed_colour(location=channel), ) - await channel.trigger_typing() + if channel.permissions_for(channel.guild.me).send_messages: + await channel.trigger_typing() if animation_message_deleted is False: try: await animation_message.edit(embed=new_embed)