X-Git-Url: http://gitweb.michael.orlitzky.com/?p=dead%2Flwn-epub.git;a=blobdiff_plain;f=src%2FLWN%2FPage.hs;fp=src%2FLWN%2FPage.hs;h=c39a2f5126fd6d474f3ec0d902662a4f6c42d176;hp=3d53284c4b66e9c67ff222d19982ce4e2ced45d2;hb=c07b67fc6fafd67364686ee51f844e0ac5b790d6;hpb=9fa662fa8ea24478949099d465efb8eb6599e745 diff --git a/src/LWN/Page.hs b/src/LWN/Page.hs index 3d53284..c39a2f5 100644 --- a/src/LWN/Page.hs +++ b/src/LWN/Page.hs @@ -163,8 +163,9 @@ replace_remote_img_srcs image_map = change_src_func :: String -> String change_src_func old_src = case Map.lookup old_src image_map of - -- Leave it alone if we don't have the file locally - Nothing -> old_src + -- If we don't have the file, empty the src. Pandoc will crash + -- otherwise. + Nothing -> "" Just v -> v change_src :: (ArrowXml a) => a XmlTree XmlTree