def addquote(self, ctx, message: str, *, author: str = None):
"""Adds a quote to the server quote list. The quote must be enclosed
in \"double quotes\". If a member mention or name is the last argument,
the quote will be stored as theirs. If not, the last argument will
be stored as the quote's author. If left empty, "Unknown" is used.
"""
if author:
try:
author = commands.MemberConverter(ctx, author).convert()
except commands.errors.BadArgument:
author = author.strip(' \t\n\r\x0b\x0c-–—') # whitespace + dashes
pass
self._add_quote(ctx, author, message)
await self.bot.say("Quote added.")
评论列表
文章目录