From 3453d155d8bdaf406852f9989cb4f7875c610faf Mon Sep 17 00:00:00 2001 From: Siphalor Date: Wed, 27 Jan 2021 16:27:00 +0100 Subject: [PATCH] Fix quote reorganization --- bot.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/bot.py b/bot.py index f58ab2a..cedd792 100644 --- a/bot.py +++ b/bot.py @@ -267,10 +267,10 @@ async def quote_command(ctx: commands.Context, author: Optional[str], *, quote: quote = quote[0].upper() + quote[1::] if author in quotes: author_quotes: List[str] = quotes[author] - regex = re.compile(r'[\W]') - stripped_quote = regex.sub(quote, '').lower() + regex = re.compile(r'\W') + stripped_quote = regex.sub('', quote).lower() for aq in author_quotes: - if regex.sub(aq, '').lower() == stripped_quote: + if regex.sub('', aq).lower() == stripped_quote: await ctx.channel.send("Quote already exists!") return