1
0
Fork 0
mirror of synced 2024-04-25 16:22:15 +12:00

Use when_mentioned_or

This commit is contained in:
Dan Hess 2021-04-24 15:41:48 -08:00
parent 503cb105cd
commit 0c8dfa162b

View file

@ -1,6 +1,8 @@
import yaml
import asyncio
from discord.ext import commands
loop = asyncio.get_event_loop()
global_config = {}
@ -113,4 +115,6 @@ db_opts = {
def command_prefix(bot, message):
if not message.guild:
return default_prefix
return bot.cache.prefixes.get(message.guild.id) or default_prefix
return commands.when_mentioned_or(
bot.cache.prefixes.get(message.guild.id) or default_prefix
)(bot, message)