diff --git a/src/Blaze/Senza.hs b/src/Blaze/Senza.hs index 9d669e8..5e97c28 100644 --- a/src/Blaze/Senza.hs +++ b/src/Blaze/Senza.hs @@ -1,4 +1,4 @@ --- | Blaze without attribute operators +-- | Blaze without attribute operators. module Blaze.Senza where diff --git a/src/HL/M/Wiki.hs b/src/HL/M/Wiki.hs index 7efcc9d..cf364b6 100644 --- a/src/HL/M/Wiki.hs +++ b/src/HL/M/Wiki.hs @@ -29,13 +29,14 @@ import Text.XML.Cursor getWikiPage :: Text -> IO (Either Text (Text,Pandoc)) getWikiPage article = do request <- parseUrl ("http://www.haskell.org/haskellwiki/Special:Export/" <> unpack article) - withManager $ \manager -> do - response <- http request manager - doc <- catch (fmap Just (responseBody response $$+- sinkDoc def)) - (\(_::UnresolvedEntityException) -> return Nothing) - case doc >>= parse of - Nothing -> return (Left "Unable to parse XML from haskell.org.") - Just (title,pan) -> return (Right (title,pan)) + withManager + (\manager -> + do response <- http request manager + doc <- catch (fmap Just (responseBody response $$+- sinkDoc def)) + (\(_::UnresolvedEntityException) -> return Nothing) + case doc >>= parse of + Nothing -> return (Left "Unable to parse XML from haskell.org.") + Just (title,pan) -> return (Right (title,pan))) where parse doc = do let cursor = fromDocument doc diff --git a/src/HL/V/Template.hs b/src/HL/V/Template.hs index 1e4c456..a77a37f 100644 --- a/src/HL/V/Template.hs +++ b/src/HL/V/Template.hs @@ -93,8 +93,9 @@ bread url crumbs = ol [class_ "breadcrumb"] (forM_ crumbs (\route -> - li [] (a [href (url route)] - (toHtml (fromRoute route))))) + li [] + (a [href (url route)] + (toHtml (fromRoute route))))) -- | Generate a human-readable string from a route. fromRoute :: Route App -> Text