diff options
author | Sam Truzjan <pxqr.sta@gmail.com> | 2014-02-26 12:05:42 +0400 |
---|---|---|
committer | Sam Truzjan <pxqr.sta@gmail.com> | 2014-02-26 12:05:42 +0400 |
commit | d8dba40ba5431182ab6acdcadc619d8c4fa8206a (patch) | |
tree | 88aff17429d5d47b8bb2d5fd8e92a9ee071e45b7 /src | |
parent | 6d381df09aecc797d9e20acaf5996399c21a6916 (diff) |
Bump http-conduit dependency
Diffstat (limited to 'src')
-rw-r--r-- | src/Network/BitTorrent/Tracker/RPC/HTTP.hs | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/Network/BitTorrent/Tracker/RPC/HTTP.hs b/src/Network/BitTorrent/Tracker/RPC/HTTP.hs index 32a5e79c..c5bf4e31 100644 --- a/src/Network/BitTorrent/Tracker/RPC/HTTP.hs +++ b/src/Network/BitTorrent/Tracker/RPC/HTTP.hs | |||
@@ -43,8 +43,9 @@ import Data.Typeable | |||
43 | import Network.URI | 43 | import Network.URI |
44 | import Network.HTTP.Conduit hiding | 44 | import Network.HTTP.Conduit hiding |
45 | (Manager, newManager, closeManager, withManager) | 45 | (Manager, newManager, closeManager, withManager) |
46 | import Network.HTTP.Client (defaultManagerSettings) | ||
47 | import Network.HTTP.Client.Internal (setUri) | ||
46 | import qualified Network.HTTP.Conduit as HTTP | 48 | import qualified Network.HTTP.Conduit as HTTP |
47 | import Network.HTTP.Conduit.Internal (setUri) | ||
48 | import Network.HTTP.Types.Header (hUserAgent) | 49 | import Network.HTTP.Types.Header (hUserAgent) |
49 | import Network.HTTP.Types.URI (SimpleQuery, renderSimpleQuery) | 50 | import Network.HTTP.Types.URI (SimpleQuery, renderSimpleQuery) |
50 | 51 | ||
@@ -92,7 +93,7 @@ instance Default Options where | |||
92 | { optAnnounceExt = def | 93 | { optAnnounceExt = def |
93 | , optHttpProxy = Nothing | 94 | , optHttpProxy = Nothing |
94 | , optUserAgent = BC.pack libUserAgent | 95 | , optUserAgent = BC.pack libUserAgent |
95 | , optHttpOptions = def | 96 | , optHttpOptions = defaultManagerSettings |
96 | } | 97 | } |
97 | 98 | ||
98 | -- | HTTP tracker manager. | 99 | -- | HTTP tracker manager. |
@@ -114,7 +115,7 @@ withManager opts = bracket (newManager opts) closeManager | |||
114 | -- Queries | 115 | -- Queries |
115 | -----------------------------------------------------------------------} | 116 | -----------------------------------------------------------------------} |
116 | 117 | ||
117 | fillRequest :: Options -> SimpleQuery -> Request m -> Request m | 118 | fillRequest :: Options -> SimpleQuery -> Request -> Request |
118 | fillRequest Options {..} q r = r | 119 | fillRequest Options {..} q r = r |
119 | { queryString = joinQuery (queryString r) (renderSimpleQuery False q) | 120 | { queryString = joinQuery (queryString r) (renderSimpleQuery False q) |
120 | , requestHeaders = (hUserAgent, optUserAgent) : requestHeaders r | 121 | , requestHeaders = (hUserAgent, optUserAgent) : requestHeaders r |