From e0d21dbb820434761488e42d3273c93126647e8b Mon Sep 17 00:00:00 2001 From: John MacFarlane Date: Sat, 11 Feb 2017 09:06:49 +0100 Subject: Class.report: Save all log messages in state. Verbosity level only affects which are printed to stdout. (Exception: DEBUG messages are only printed, never saved to state.) --- src/Text/Pandoc/Class.hs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Text/Pandoc/Class.hs b/src/Text/Pandoc/Class.hs index 0788a9d86..fb148666c 100644 --- a/src/Text/Pandoc/Class.hs +++ b/src/Text/Pandoc/Class.hs @@ -146,8 +146,8 @@ report msg = do let level = messageVerbosity msg when (level <= verbosity) $ do logOutput msg - unless (level == DEBUG) $ - modifyCommonState $ \st -> st{ stLog = msg : stLog st } + unless (level == DEBUG) $ + modifyCommonState $ \st -> st{ stLog = msg : stLog st } setMediaBag :: PandocMonad m => MediaBag -> m () setMediaBag mb = modifyCommonState $ \st -> st{stMediaBag = mb} -- cgit v1.2.1