From 531c9821ae4d327a93e006d6688b72707434075e Mon Sep 17 00:00:00 2001 From: Kwoth Date: Tue, 26 Jul 2016 01:02:02 +0200 Subject: [PATCH] Lets try doing this for fun --- NadekoBot/Modules/Games/Commands/PlantPick.cs | 11 +++++++++-- NadekoBot/Modules/Games/Commands/PollCommand.cs | 5 ----- 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/NadekoBot/Modules/Games/Commands/PlantPick.cs b/NadekoBot/Modules/Games/Commands/PlantPick.cs index e2bce2ec..d2882eb2 100644 --- a/NadekoBot/Modules/Games/Commands/PlantPick.cs +++ b/NadekoBot/Modules/Games/Commands/PlantPick.cs @@ -79,8 +79,15 @@ namespace NadekoBot.Modules.Games.Commands await FlowersHandler.AddFlowersAsync(e.User, "Picked a flower.", 1, true).ConfigureAwait(false); var msg = await e.Channel.SendMessage($"**{e.User.Name}** picked a {NadekoBot.Config.CurrencyName}!").ConfigureAwait(false); - await Task.Delay(10000).ConfigureAwait(false); - await msg.Delete().ConfigureAwait(false); + ThreadPool.QueueUserWorkItem(async (state) => + { + try + { + await Task.Delay(10000).ConfigureAwait(false); + await msg.Delete().ConfigureAwait(false); + } + catch { } + }); }); cgb.CreateCommand(Module.Prefix + "plant") diff --git a/NadekoBot/Modules/Games/Commands/PollCommand.cs b/NadekoBot/Modules/Games/Commands/PollCommand.cs index e1cd75e4..0e1bb81c 100644 --- a/NadekoBot/Modules/Games/Commands/PollCommand.cs +++ b/NadekoBot/Modules/Games/Commands/PollCommand.cs @@ -15,11 +15,6 @@ namespace NadekoBot.Modules.Games.Commands public static ConcurrentDictionary ActivePolls = new ConcurrentDictionary(); - public Func DoFunc() - { - throw new NotImplementedException(); - } - internal override void Init(CommandGroupBuilder cgb) { cgb.CreateCommand(Module.Prefix + "poll")