ranon-rat / haskell-discord-compiler

a simple discord compiler made in haskell( FINISHED)
https://discord.gg/e52RFh7Cg2
BSD 3-Clause "New" or "Revised" License
10 stars 0 forks source link

idk why im having this error #1

Closed ranon-rat closed 3 years ago

ranon-rat commented 3 years ago

idk why im having this error , HELP

• Couldn't match type ‘IO’
                 with ‘transformers-0.5.6.2:Control.Monad.Trans.Reader.ReaderT
                         Discord.Handle.DiscordHandle IO’
  Expected type: DiscordHandler ()
    Actual type: IO ()
• In the expression:
    when (not (fromBot m) && isPing (messageText m))
      $ do xd <- executeCode m
           pure ()
  In a case alternative:
      MessageCreate m
        -> when (not (fromBot m) && isPing (messageText m))
             $ do xd <- executeCode m
                  pure ()
  In the expression:
    case event of
      MessageCreate m
        -> when (not (fromBot m) && isPing (messageText m))
             $ do xd <- executeCode m
                  pure ()
      _ -> pure ()
ranon-rat commented 3 years ago

 messReq <- liftIO (executeCode m)

source

... lol