[option 'dumpLog' has been ignored, and log was always dumped
martin.hofmann@uni-bamberg.de**20090519082611] hunk ./src/UI/UIStarter.hs 289
-    when (not $ dumpLog s) $ return ()
-    when (not exist) $ putStrLn ("Log not dumped! Directory not found: " ++ (dumpDir s)) >> return()
-    date    <- showDate
-    file    <- return ((dumpDir s) ++ "/" ++ date ++ ".log")
-    fhandle <- openFile file AppendMode
-    hPutDoc fhandle d
-    hClose fhandle
+    if (not $ dumpLog s) then return ()
+      else if (not exist) then printErr
+             else writeLog
+    where
+    printErr =  putStrLn ("Log not dumped! Directory not found: " ++ 
+                          (dumpDir s)) >> return()
+    writeLog = do date    <- showDate
+                  file    <- return ((dumpDir s) ++ "/" ++ date ++ ".log")
+                  fhandle <- openFile file AppendMode
+                  hPutDoc fhandle d
+                  hClose fhandle