diff options
| author | John MacFarlane <jgm@berkeley.edu> | 2022-08-09 15:37:47 -0700 |
|---|---|---|
| committer | John MacFarlane <jgm@berkeley.edu> | 2022-08-09 15:37:47 -0700 |
| commit | 7a35e7ee684ce40b4d3875da17ce74cfcae0475f (patch) | |
| tree | 3cd4f1f15e0f7161564ab9c4787394958c94eea3 /server | |
| parent | 5db3f96400f4344dc15cfb596e18dda769f44f86 (diff) | |
Server - set standalone by default to true if binary output.
Diffstat (limited to 'server')
| -rw-r--r-- | server/PandocServer.hs | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/server/PandocServer.hs b/server/PandocServer.hs index c89502b51..644cb0b92 100644 --- a/server/PandocServer.hs +++ b/server/PandocServer.hs @@ -85,7 +85,10 @@ server = convert let writerFormat = fromMaybe "html" $ to params (readerSpec, readerExts) <- getReader readerFormat (writerSpec, writerExts) <- getWriter writerFormat - let isStandalone = fromMaybe False (standalone params) + let binaryOutput = case writerSpec of + ByteStringWriter{} -> True + _ -> False + let isStandalone = fromMaybe binaryOutput (standalone params) let toformat = T.toLower $ T.takeWhile isAlphaNum $ writerFormat mbTemplate <- if isStandalone then case template params of |
