コード例 #1
0
ファイル: reminder.cs プロジェクト: djthegr8/RoleX
 public async Task ReminderCommand(params string[] args)
 {
     if (args.Length == 0 || args[0] == "list")
     {
         await ReplyAsync("", false, new EmbedBuilder
         {
             Title       = "Your current reminders!",
             Description =
                 $"{((await SqliteClass.GetReminders($"SELECT * FROM reminders WHERE UserID = {Context.User.Id} AND Finished IS 0;")).Count == 0 ? "User has no reminders" : "```\n" + string.Join('\n', (await SqliteClass.GetReminders($"SELECT * FROM reminders WHERE UserID = {Context.User.Id} AND Finished IS 0;")).Select(x => $"ID: {x.Id}\tTime: {x.TimeS:U}\tReason:{x.Reason}")) + "```")}",
             Color = Blurple
         }.WithCurrentTimestamp());