fix: made evidence be declared as None if there is no evidence given

This commit is contained in:
Seaswimmer 2023-08-08 02:00:25 -04:00
parent 98bc2b7cc1
commit 33d966c0e5
No known key found for this signature in database
GPG key ID: 5019678FD9CF50D8

View file

@ -52,6 +52,8 @@ class Shortmute(commands.Cog):
evidence = evidence_link
elif evidence_image:
evidence = str(evidence_image)
else:
evidence = None
immune_roles_list = await self.config.guild(interaction.guild).immune_roles()
for role_id in immune_roles_list:
role = interaction.guild.get_role(role_id)