Skip to content

Commit

Permalink
[Discord] Broaden audio resume command permission to administrators
Browse files Browse the repository at this point in the history
  • Loading branch information
Harmon758 committed Nov 20, 2023
1 parent 01e6822 commit f4c21fa
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 @@ -351,7 +351,10 @@ async def pause(self, ctx):
name = "resume", aliases = ["start"], with_app_command = False
)
@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_resume(self, ctx):
'''Resume the current song'''
# Note: resume command invokes this command
Expand All @@ -370,7 +373,10 @@ async def audio_resume(self, ctx):

@commands.command(aliases = ["start"])
@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 resume(self, ctx):
'''Resume the current song'''
if command := ctx.bot.get_command("audio resume"):
Expand Down

0 comments on commit f4c21fa

Please sign in to comment.