Org reader: report errors properly

Errors during parsing are now returned in full and no longer replaced by
a custom message.
This commit is contained in:
Albert Krewinkel 2019-12-19 20:26:55 +01:00
parent 0a3cc7260c
commit b06124e43a
No known key found for this signature in database
GPG key ID: 388DC0B21F631124

View file

@ -18,7 +18,6 @@ import Text.Pandoc.Readers.Org.Parsing (OrgParser, readWithM)
import Text.Pandoc.Class (PandocMonad)
import Text.Pandoc.Definition
import Text.Pandoc.Error
import Text.Pandoc.Options
import Text.Pandoc.Parsing (reportLogMessages)
import Text.Pandoc.Shared (crFilter)
@ -39,7 +38,7 @@ readOrg opts s = do
(crFilter s <> "\n\n")
case parsed of
Right result -> return result
Left _ -> throwError $ PandocParseError "problem parsing org"
Left e -> throwError e
--
-- Parser