Skip to content

Commit

Permalink
[Discord] Broaden audio undeafen command permission to administrators
Browse files Browse the repository at this point in the history
  • Loading branch information
Harmon758 committed Nov 21, 2023
1 parent 377a91c commit f7c24b8
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions Discord/cogs/audio.py
Original file line number Diff line number Diff line change
Expand Up @@ -1083,7 +1083,10 @@ async def mute(self, ctx):

@audio.command(name = "undeafen")
@checks.is_voice_connected()
@commands.check_any(checks.is_permitted(), checks.is_guild_owner())
@commands.check_any(
checks.is_permitted(), commands.has_permissions(administrator = True),
commands.is_owner()
)
async def audio_undeafen(self, ctx):
'''Have me undeafen myself'''
# Note: undeafen command invokes this command
Expand All @@ -1098,7 +1101,10 @@ async def audio_undeafen(self, ctx):

@commands.command()
@checks.is_voice_connected()
@commands.check_any(checks.is_permitted(), checks.is_guild_owner())
@commands.check_any(
checks.is_permitted(), commands.has_permissions(administrator = True),
commands.is_owner()
)
async def undeafen(self, ctx):
'''Have me undeafen myself'''
if command := ctx.bot.get_command("audio undeafen"):
Expand Down

0 comments on commit f7c24b8

Please sign in to comment.