diff options
author | Teddy Wing | 2017-08-16 02:49:21 +0200 |
---|---|---|
committer | Teddy Wing | 2017-08-16 02:49:21 +0200 |
commit | 76960b444b3562ae56f877b8f05c8abd4e0e4d1a (patch) | |
tree | 4ced5600a8b4ac3a02775c7007b1131a6e32cd45 /src/IRC.hs | |
parent | 63b5c7bcd7bd72234a3f25e7ce5cc5df23a4dc95 (diff) | |
download | sorbot-76960b444b3562ae56f877b8f05c8abd4e0e4d1a.tar.bz2 |
Remove commented code from a0d21d9aed3a38e98e622fbae5fcab3e91c5ddee
I had a bunch of code commented from earlier and from false starts when
working on integrating my plugins and the IRC message handler. Remove
these commented lines now as they are no longer relevant. The actual
code is functioning.
Diffstat (limited to 'src/IRC.hs')
-rw-r--r-- | src/IRC.hs | 12 |
1 files changed, 0 insertions, 12 deletions
@@ -31,24 +31,18 @@ handlePrivmsg = IRC.EventHandler } where dispatchEvent (IRC.Event _ (IRC.User nick) (IRC.Privmsg _ (Right msg))) = do - -- IRC.send $ IRC.Privmsg nick (Right "test") let message = Message { text = T.unpack msg , channel = T.unpack nick , nick = T.unpack nick } Just plugin = matchPlugin message - -- rsp =<< performPlugin plugin message - -- IRC.send case performPlugin plugin message of - -- Left err -> IRC.Privmsg nick (Right (T.pack err)) - -- Right r -> IRC.Privmsg nick (Right (T.pack r)) response <- liftIO $ performPlugin plugin message IRC.send $ case response of Left err -> IRC.Privmsg nick (Right (T.pack err)) Right r -> IRC.Privmsg nick (Right (T.pack r)) dispatchEvent (IRC.Event _ (IRC.Channel chan nick) (IRC.Privmsg _ (Right msg))) = do - -- IRC.send $ IRC.Privmsg chan (Right "test") let message = Message { text = T.unpack msg , channel = T.unpack chan @@ -59,9 +53,3 @@ handlePrivmsg = IRC.EventHandler IRC.send $ case response of Left err -> IRC.Privmsg chan (Right (T.pack err)) Right r -> IRC.Privmsg chan (Right (T.pack r)) - - -- let Just plugin = matchPlugin message - -- response <- performPlugin plugin message - -- putStrLn $ case response of - -- Left e -> e - -- Right r -> r |