From 2b397f960db31332d850d102c0aeb124061e1713 Mon Sep 17 00:00:00 2001 From: Joseph Ferano Date: Wed, 22 Jun 2022 00:25:10 +0700 Subject: [PATCH] Missed one --- Bot/Games/HackerBattle.fs | 2 +- Bot/Games/Trainer.fs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Bot/Games/HackerBattle.fs b/Bot/Games/HackerBattle.fs index 4b75c96..a0c00b5 100644 --- a/Bot/Games/HackerBattle.fs +++ b/Bot/Games/HackerBattle.fs @@ -284,7 +284,7 @@ let handleButtonEvent _ (event : ComponentInteractionCreateEventArgs) = match event.Id with | id when id.StartsWith("Attack") -> handleAttack eventCtx | id when id.StartsWith("Defend") -> handleDefense eventCtx - | id when id.StartsWith("Trainer") -> Trainer.handleButtonEvent eventCtx |> Async.StartAsTask :> Task + | id when id.StartsWith("Trainer") -> Trainer.handleButtonEvent eventCtx | id when id.StartsWith("Steal") -> Thief.handleSteal eventCtx | id when id.StartsWith("RPS") -> RockPaperScissors.handleRPS eventCtx | _ -> diff --git a/Bot/Games/Trainer.fs b/Bot/Games/Trainer.fs index a261490..e8bb44d 100644 --- a/Bot/Games/Trainer.fs +++ b/Bot/Games/Trainer.fs @@ -249,5 +249,6 @@ let handleButtonEvent (ctx : IDiscordContext) = | 3 -> do! handleTrainerStep3 ctx |> Async.AwaitTask | 4 -> do! handleHack ctx |> Async.AwaitTask | _ -> do! sendFollowUpMessage ctx "No action found" - } + } |> Async.Start + Task.CompletedTask