merge hlint changes from propellor

This commit is contained in:
Joey Hess 2015-09-13 13:39:48 -04:00
parent 6ce5fea50c
commit 2d2e94798f
4 changed files with 8 additions and 12 deletions

View file

@ -39,10 +39,7 @@ catchBoolIO = catchDefaultIO False
{- Catches IO errors and returns a Maybe -}
catchMaybeIO :: MonadCatch m => m a -> m (Maybe a)
catchMaybeIO a = do
catchDefaultIO Nothing $ do
v <- a
return (Just v)
catchMaybeIO a = catchDefaultIO Nothing $ a >>= (return . Just)
{- Catches IO errors and returns a default value. -}
catchDefaultIO :: MonadCatch m => a -> m a -> m a