aboutsummaryrefslogtreecommitdiff
path: root/src/Text/Pandoc/Writers/RTF.hs
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2017-09-30 16:07:47 -0500
committerJohn MacFarlane <jgm@berkeley.edu>2017-09-30 16:11:20 -0500
commitf3a80034fff41a8b0c13519fa13bed794db1b8d2 (patch)
tree8355bd3c88b87b960171a65aad05b36e6822e8a4 /src/Text/Pandoc/Writers/RTF.hs
parent9b7d652ab7a0f4cdd86efd92f43f1b20724e8982 (diff)
downloadpandoc-f3a80034fff41a8b0c13519fa13bed794db1b8d2.tar.gz
Removed writerSourceURL, add source URL to common state.
Removed `writerSourceURL` from `WriterOptions` (API change). Added `stSourceURL` to `CommonState`. It is set automatically by `setInputFiles`. Text.Pandoc.Class now exports `setInputFiles`, `setOutputFile`. The type of `getInputFiles` has changed; it now returns `[FilePath]` instead of `Maybe [FilePath]`. Functions in Class that formerly took the source URL as a parameter now have one fewer parameter (`fetchItem`, `downloadOrRead`, `setMediaResource`, `fillMediaBag`). Removed `WriterOptions` parameter from `makeSelfContained` in `SelfContained`.
Diffstat (limited to 'src/Text/Pandoc/Writers/RTF.hs')
-rw-r--r--src/Text/Pandoc/Writers/RTF.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Writers/RTF.hs b/src/Text/Pandoc/Writers/RTF.hs
index 48d31c7bf..d4de3112c 100644
--- a/src/Text/Pandoc/Writers/RTF.hs
+++ b/src/Text/Pandoc/Writers/RTF.hs
@@ -56,7 +56,7 @@ import Text.Printf (printf)
-- If file not found or filetype not jpeg or png, leave the inline unchanged.
rtfEmbedImage :: PandocMonad m => WriterOptions -> Inline -> m Inline
rtfEmbedImage opts x@(Image attr _ (src,_)) = catchError
- (do result <- P.fetchItem (writerSourceURL opts) src
+ (do result <- P.fetchItem src
case result of
(imgdata, Just mime)
| mime == "image/jpeg" || mime == "image/png" -> do