diff --git a/src/Text/Pandoc/App.hs b/src/Text/Pandoc/App.hs index 6d22087853ab..cd66d0098d6a 100644 --- a/src/Text/Pandoc/App.hs +++ b/src/Text/Pandoc/App.hs @@ -297,8 +297,8 @@ convertWithOpts' scriptingEngine istty datadir opts = do >>= ( return . adjustMetadata (metadataFromFile <>) >=> return . adjustMetadata (<> optMetadata opts) >=> return . adjustMetadata (<> cslMetadata) - >=> applyTransforms transforms >=> applyFilters scriptingEngine filterEnv filters [T.unpack format] + >=> applyTransforms transforms >=> (if not (optSandbox opts) && (isJust (optExtractMedia opts) || format == "docx") -- for fallback pngs