mirror of
https://github.com/Cog-Creators/Red-DiscordBot.git
synced 2025-12-06 09:22:31 -05:00
Make it possible to set slowmode in stage/voice channels (#6108)
This commit is contained in:
@@ -30,9 +30,6 @@ class Slowmode(MixinMeta):
|
|||||||
Interval can be anything from 0 seconds to 6 hours.
|
Interval can be anything from 0 seconds to 6 hours.
|
||||||
Use without parameters to disable.
|
Use without parameters to disable.
|
||||||
"""
|
"""
|
||||||
if not isinstance(ctx.channel, (discord.TextChannel, discord.Thread)):
|
|
||||||
await ctx.send(_("Slowmode can only be set in text channels and threads."))
|
|
||||||
return
|
|
||||||
seconds = interval.total_seconds()
|
seconds = interval.total_seconds()
|
||||||
await ctx.channel.edit(slowmode_delay=seconds)
|
await ctx.channel.edit(slowmode_delay=seconds)
|
||||||
if seconds > 0:
|
if seconds > 0:
|
||||||
|
|||||||
Reference in New Issue
Block a user