summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichaelSnoyman <>2014-08-25 10:42:00 (GMT)
committerhdiff <hdiff@hdiff.luite.com>2014-08-25 10:42:00 (GMT)
commit0a33ad0ef5bc164e566a523ca17c7e0db22b65b3 (patch)
tree0b8fe39e10e91ba571071718ec271d248d3057b4
parent9122bdf8c49c15f9ed81a74eeaee2c766be1ed54 (diff)
version 2.1.4.12.1.4.1
-rw-r--r--Network/HTTP/Conduit.hs5
-rw-r--r--http-conduit.cabal2
2 files changed, 4 insertions, 3 deletions
diff --git a/Network/HTTP/Conduit.hs b/Network/HTTP/Conduit.hs
index 9e92003..04eb76c 100644
--- a/Network/HTTP/Conduit.hs
+++ b/Network/HTTP/Conduit.hs
@@ -49,6 +49,7 @@
-- > import Data.Time.Clock
-- > import Data.Time.Calendar
-- > import qualified Control.Exception as E
+-- > import Network.HTTP.Types.Status (statusCode)
-- >
-- > past :: UTCTime
-- > past = UTCTime (ModifiedJulianDay 56200) (secondsToDiffTime 0)
@@ -73,9 +74,9 @@
-- > main = withSocketsDo $ do
-- > request' <- parseUrl "http://example.com/secret-page"
-- > let request = request' { cookieJar = Just $ createCookieJar [cookie] }
--- > E.catch (withManager $ httpLbs request)
+-- > (fmap Just (withManager $ httpLbs request)) `E.catch`
-- > (\(StatusCodeException s _ _) ->
--- > if statusCode==403 then putStrLn "login failed" else return ())
+-- > if statusCode s==403 then (putStrLn "login failed" >> return Nothing) else return Nothing)
--
-- Any network code on Windows requires some initialization, and the network
-- library provides withSocketsDo to perform it. Therefore, proper usage of
diff --git a/http-conduit.cabal b/http-conduit.cabal
index 783528b..46f1220 100644
--- a/http-conduit.cabal
+++ b/http-conduit.cabal
@@ -1,5 +1,5 @@
name: http-conduit
-version: 2.1.4
+version: 2.1.4.1
license: BSD3
license-file: LICENSE
author: Michael Snoyman <michael@snoyman.com>