From: Michael Orlitzky Date: Sat, 1 Dec 2012 05:05:59 +0000 (-0500) Subject: Bump a few dependencies, fix compilation failures. X-Git-Url: https://gitweb.michael.orlitzky.com/?a=commitdiff_plain;ds=inline;p=dead%2Flwn-epub.git Bump a few dependencies, fix compilation failures. --- diff --git a/lwn-epub.cabal b/lwn-epub.cabal index 1d104b6..c8331ae 100644 --- a/lwn-epub.cabal +++ b/lwn-epub.cabal @@ -19,19 +19,19 @@ data-files: makefile doc/README executable lwn-epub build-depends: - base == 4.5.*, - bytestring == 0.9.*, + base == 4.6.*, + bytestring == 0.10.*, cmdargs == 0.10.*, ConfigFile == 1.*, containers == 0.*, - directory == 1.1.*, + directory == 1.2.*, filepath == 1.3.*, HandsomeSoup == 0.3.*, - http-conduit == 1.6.*, + http-conduit == 1.8.*, http-types == 0.7.*, hxt == 9.*, - MissingH == 1.1.*, - network == 2.3.*, + MissingH == 1.2.*, + network == 2.4.*, pandoc == 1.9.*, parallel-io == 0.3.*, regex-posix == 0.95.*, @@ -91,11 +91,11 @@ test-suite testsuite directory == 1.1.*, filepath == 1.3.*, HandsomeSoup == 0.3.*, - http-conduit == 1.6.*, + http-conduit == 1.8.*, http-types == 0.7.*, hxt == 9.*, - MissingH == 1.1.*, - network == 2.3.*, + MissingH == 1.2.*, + network == 2.4.*, pandoc == 1.9.*, parallel-io == 0.3.*, regex-posix == 0.95.*, diff --git a/src/LWN/Page.hs b/src/LWN/Page.hs index c39a2f5..5f3b9ee 100644 --- a/src/LWN/Page.hs +++ b/src/LWN/Page.hs @@ -4,11 +4,10 @@ module LWN.Page where import Control.Concurrent.ParallelIO (parallel) -import qualified Data.Map as Map (lookup) import Data.Time (getCurrentTime) import qualified Data.ByteString.Lazy as B (ByteString, hPut) import Data.String.Utils (split, strip) -import qualified Data.Map as Map (Map, empty, insert) +import qualified Data.Map as Map (Map, empty, insert, lookup) import Data.Maybe (catMaybes, fromJust, isNothing) import Prelude hiding (readFile) import System.IO (Handle, hClose, hFlush) diff --git a/src/LWN/URI.hs b/src/LWN/URI.hs index f20c294..7a0a41f 100644 --- a/src/LWN/URI.hs +++ b/src/LWN/URI.hs @@ -149,7 +149,7 @@ filename url = -make_absolute_uri :: URI -> Maybe URI +make_absolute_uri :: URI -> URI make_absolute_uri relative_uri = relativeTo relative_uri base_uri where @@ -168,10 +168,7 @@ make_absolute_url relative_url = case parse_result of Nothing -> Nothing Just relative_uri -> - let abs_result = make_absolute_uri relative_uri in - case abs_result of - Nothing -> Nothing - Just abs_uri -> Just $ show abs_uri + Just $ show $ make_absolute_uri relative_uri where parse_result = parseURIReference relative_url