aboutsummaryrefslogtreecommitdiff
path: root/src/Text
diff options
context:
space:
mode:
authorJohn MacFarlane <jgm@berkeley.edu>2019-01-24 16:21:57 -0800
committerJohn MacFarlane <jgm@berkeley.edu>2019-01-24 16:21:57 -0800
commitb08c8627d30fdaf991fdff1fd7f3d674b356a976 (patch)
tree706f977056e2e7d37f48ad7852bc32bea6d4541c /src/Text
parent22b09d88ff8b13e2bdfa25781d9143878791581c (diff)
downloadpandoc-b08c8627d30fdaf991fdff1fd7f3d674b356a976.tar.gz
Allow some command line options to take URL in addition to FILE.
`--include-in-header`, `--include-before-body`, `--include-after-body`
Diffstat (limited to 'src/Text')
-rw-r--r--src/Text/Pandoc/App/OutputSettings.hs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/Text/Pandoc/App/OutputSettings.hs b/src/Text/Pandoc/App/OutputSettings.hs
index b4bd9a4b2..0f4923ea4 100644
--- a/src/Text/Pandoc/App/OutputSettings.hs
+++ b/src/Text/Pandoc/App/OutputSettings.hs
@@ -128,8 +128,8 @@ optToOutputSettings opts = do
withList f (x:xs) vars = f x vars >>= withList f xs
let addContentsAsVariable varname fp vars = do
- s <- UTF8.toString <$> readFileStrict fp
- return $ (varname, s) : vars
+ s <- UTF8.toString . fst <$> fetchItem fp
+ return $ (varname, s) : vars
variables <-
withList (addStringAsVariable "sourcefile")