mirror of
https://gitlab.com/Kwoth/nadekobot.git
synced 2025-09-11 01:38:27 -04:00
Removed unwanted command
This commit is contained in:
@@ -196,37 +196,6 @@ namespace NadekoBot.Modules.Utility
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
[NadekoCommand, Aliases]
|
|
||||||
public async Task ServerRemindDelete(int index)
|
|
||||||
{
|
|
||||||
if (--index < 0)
|
|
||||||
return;
|
|
||||||
|
|
||||||
Reminder rem = null;
|
|
||||||
using (var uow = _db.GetDbContext())
|
|
||||||
{
|
|
||||||
var rems = uow.Reminders
|
|
||||||
.RemindersForServer(ctx.Guild.Id, index / 10)
|
|
||||||
.ToList();
|
|
||||||
var pageIndex = index % 10;
|
|
||||||
if (rems.Count > pageIndex)
|
|
||||||
{
|
|
||||||
rem = rems[pageIndex];
|
|
||||||
uow.Reminders.Remove(rem);
|
|
||||||
uow.SaveChanges();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (rem is null)
|
|
||||||
{
|
|
||||||
await ReplyErrorLocalizedAsync(strs.reminder_not_exist).ConfigureAwait(false);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
await ReplyConfirmLocalizedAsync(strs.reminder_deleted(index + 1));
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
private async Task<bool> RemindInternal(ulong targetId, bool isPrivate, TimeSpan ts, string message)
|
private async Task<bool> RemindInternal(ulong targetId, bool isPrivate, TimeSpan ts, string message)
|
||||||
{
|
{
|
||||||
var time = DateTime.UtcNow + ts;
|
var time = DateTime.UtcNow + ts;
|
||||||
|
Reference in New Issue
Block a user