Archived
1
0
Fork 0

Fixed several stuff.

This commit is contained in:
Julien Dessaux 2010-04-21 20:57:22 +02:00
parent bfc06f1ff1
commit 4c76d3d40b
10 changed files with 25 additions and 21 deletions

View file

@ -4,9 +4,9 @@ module Hsbot.Core
) where
import Control.Concurrent
import Control.Concurrent.Chan
import Control.Concurrent.Chan()
import Control.Monad.State
import Data.List
import Data.List()
import qualified Data.Map as M
import Network
import System.IO
@ -36,8 +36,8 @@ connectServer server = do
disconnectServer :: IrcBot ()
disconnectServer = do
bot <- get
liftIO $ killThread $ readerThreadId bot
mapM_ unloadPlugin (M.keys $ botPlugins bot)
liftIO $ killThread $ readerThreadId bot
liftIO $ hClose $ botHandle bot
return ()