@@ -1060,7 +1060,7 @@ main = do
10601060 Left err' -> err 43 $ toString err'
10611061 Just w
10621062 | htmlFormat && ascii ->
1063− writerFn outputFile =<< selfcontain (toEntities result)
1063+ writerFn outputFile . toEntities =<< selfcontain result
10641064 | otherwise ->
10651065 writerFn outputFile =<< selfcontain result
10661066 where result = w writerOptions doc2 ++ ['\n' | not standalone']