From e970f53fdea63d9dd89382d522db2da570d05128 Mon Sep 17 00:00:00 2001 From: Jacques Comeaux Date: Sun, 29 May 2022 17:00:25 -0500 Subject: Use GHC 8.10 --- src/Tomato/Post.hs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'src/Tomato/Post.hs') diff --git a/src/Tomato/Post.hs b/src/Tomato/Post.hs index 4adcdbb..c97860a 100644 --- a/src/Tomato/Post.hs +++ b/src/Tomato/Post.hs @@ -23,12 +23,13 @@ import Network.HTTP.Req , responseBody ) +import Data.HashMap.Strict (insert) + import Tomato.Data.Except (DecodeException (..)) import Tomato.Data.Message (GMIUrl (..), OutMessage (..)) import Tomato.App (App (..)) import qualified Data.Aeson as Ae -import qualified Data.Aeson.KeyMap as Ae import qualified RIO.Text as T @@ -59,7 +60,7 @@ postMessage outMes = do accessToken <- asks appToken let url = https "api.groupme.com" /: "v3" /: "bots" /: "post" outMes' = case Ae.toJSON outMes of - Ae.Object o -> Ae.Object $ Ae.insert "bot_id" (Ae.toJSON botId) o + Ae.Object o -> Ae.Object $ insert "bot_id" (Ae.toJSON botId) o _ -> error "exceptional" rr $ req POST url (ReqBodyJson outMes') ignoreResponse $ header "X-Access-Token" accessToken -- cgit v1.2.3