From 4a3bb0f57eb3dd9a278f98ae062d040dd9396e20 Mon Sep 17 00:00:00 2001 From: Kwoth Date: Mon, 10 Apr 2017 03:02:46 +0200 Subject: [PATCH] sanitized mentions in quote commands --- src/NadekoBot/Modules/Utility/Commands/QuoteCommands.cs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/NadekoBot/Modules/Utility/Commands/QuoteCommands.cs b/src/NadekoBot/Modules/Utility/Commands/QuoteCommands.cs index b8819255..a11ad7c9 100644 --- a/src/NadekoBot/Modules/Utility/Commands/QuoteCommands.cs +++ b/src/NadekoBot/Modules/Utility/Commands/QuoteCommands.cs @@ -34,7 +34,7 @@ namespace NadekoBot.Modules.Utility if (quotes.Any()) await Context.Channel.SendConfirmAsync(GetText("quotes_page", page + 1), - string.Join("\n", quotes.Select(q => $"`#{q.Id}` {Format.Bold(q.Keyword),-20} by {q.AuthorName}"))) + string.Join("\n", quotes.Select(q => $"`#{q.Id}` {Format.Bold(q.Keyword.SanitizeMentions()),-20} by {q.AuthorName.SanitizeMentions()}"))) .ConfigureAwait(false); else await ReplyErrorLocalized("quotes_page_none").ConfigureAwait(false); @@ -132,7 +132,7 @@ namespace NadekoBot.Modules.Utility return; } - else { await Context.Channel.SendMessageAsync($"`#{qfromid.Id}` 🗯️ " + qfromid.Keyword.ToLowerInvariant() + ": " + + else { await Context.Channel.SendMessageAsync($"`#{qfromid.Id}` 🗯️ " + qfromid.Keyword.ToLowerInvariant().SanitizeMentions() + ": " + qfromid.Text.SanitizeMentions()); } } } @@ -208,7 +208,7 @@ namespace NadekoBot.Modules.Utility await uow.CompleteAsync(); } - await ReplyConfirmLocalized("quotes_deleted", Format.Bold(keyword)).ConfigureAwait(false); + await ReplyConfirmLocalized("quotes_deleted", Format.Bold(keyword.SanitizeMentions())).ConfigureAwait(false); } } }