aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Objectivitix <[email protected]>2021-08-23 19:23:58 -0300
committerGravatar GitHub <[email protected]>2021-08-23 19:23:58 -0300
commit934ad673e4f62df390e8017d944c9182d4ee1211 (patch)
tree6c02d69526b24221b00ae9cca203c1fa32f3b2ed
parentMerge pull request #795 from D0rs4n/pr/wikipediaissue (diff)
Whitelist `.bm` command in occupied help channels
-rw-r--r--bot/exts/evergreen/bookmark.py5
1 files changed, 4 insertions, 1 deletions
diff --git a/bot/exts/evergreen/bookmark.py b/bot/exts/evergreen/bookmark.py
index 85c9b46f..f93371a6 100644
--- a/bot/exts/evergreen/bookmark.py
+++ b/bot/exts/evergreen/bookmark.py
@@ -7,14 +7,16 @@ import discord
from discord.ext import commands
from bot.bot import Bot
-from bot.constants import Colours, ERROR_REPLIES, Icons
+from bot.constants import Categories, Colours, ERROR_REPLIES, Icons, WHITELISTED_CHANNELS
from bot.utils.converters import WrappedMessageConverter
+from bot.utils.decorators import whitelist_override
log = logging.getLogger(__name__)
# Number of seconds to wait for other users to bookmark the same message
TIMEOUT = 120
BOOKMARK_EMOJI = "📌"
+WHITELISTED_CATEGORIES = (Categories.help_in_use,)
class Bookmark(commands.Cog):
@@ -85,6 +87,7 @@ class Bookmark(commands.Cog):
await message.add_reaction(BOOKMARK_EMOJI)
return message
+ @whitelist_override(channels=WHITELISTED_CHANNELS, categories=WHITELISTED_CATEGORIES)
@commands.command(name="bookmark", aliases=("bm", "pin"))
async def bookmark(
self,