From 30a4a94f1b909f8e798aeef871a0cbfb555e7bf9 Mon Sep 17 00:00:00 2001 From: mctaylors <95250141+mctaylors@users.noreply.github.com> Date: Tue, 14 Feb 2023 17:44:29 +0300 Subject: [PATCH] Edit reminder message & add "!pardon" alias for "!unban" (#25) --- Boyfriend.cs | 5 +++-- Commands/UnbanCommand.cs | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Boyfriend.cs b/Boyfriend.cs index 58de254..b8c406b 100644 --- a/Boyfriend.cs +++ b/Boyfriend.cs @@ -170,10 +170,11 @@ public static class Boyfriend { if (now < reminder.RemindAt) continue; var channel = guild.GetTextChannel(reminder.ReminderChannel); + var toSend = $"{ReplyEmojis.Reminder} {user.Mention} {Utils.Wrap(reminder.ReminderText)}"; if (channel is not null) - await channel.SendMessageAsync($"<@{mData.Id}> {Utils.Wrap(reminder.ReminderText)}"); + await channel.SendMessageAsync(toSend); else - await Utils.SendDirectMessage(user, reminder.ReminderText); + await Utils.SendDirectMessage(user, toSend); mData.Reminders.RemoveAt(i); saveData = true; diff --git a/Commands/UnbanCommand.cs b/Commands/UnbanCommand.cs index 70abfe1..fb8040e 100644 --- a/Commands/UnbanCommand.cs +++ b/Commands/UnbanCommand.cs @@ -3,7 +3,7 @@ namespace Boyfriend.Commands; public sealed class UnbanCommand : ICommand { - public string[] Aliases { get; } = { "unban", "разбан" }; + public string[] Aliases { get; } = { "unban", "pardon", "разбан" }; public async Task RunAsync(CommandProcessor cmd, string[] args, string[] cleanArgs) { if (!cmd.HasPermission(GuildPermission.BanMembers)) return;