diff --git a/CabalDev.hs b/CabalDev.hs index a76485c..926a1cf 100644 --- a/CabalDev.hs +++ b/CabalDev.hs @@ -17,15 +17,13 @@ import Types modifyOptions :: Options -> IO Options modifyOptions opts = found ||> notFound where - found = do - path <- findCabalDev (sandbox opts) - return $ addPath opts path + found = addPath opts <$> findCabalDev (sandbox opts) notFound = return opts findCabalDev :: Maybe String -> IO FilePath findCabalDev (Just path) = do - a <- doesDirectoryExist path - if a then + exist <- doesDirectoryExist path + if exist then findConf path else findCabalDev Nothing