diff options
| author | John MacFarlane <[email protected]> | 2025-12-24 11:20:19 -0700 |
|---|---|---|
| committer | John MacFarlane <[email protected]> | 2025-12-24 11:20:19 -0700 |
| commit | 5988155f0947d1d26a8365748ac0cbe4c20f5b96 (patch) | |
| tree | b9496bff326fdf59ff074db746c46c2959c6f657 | |
| parent | ef3401ce0abac4a6334d16595c75c73c7ef5630c (diff) | |
openURL without http support: Use throwError rather than error.
| -rw-r--r-- | src/Text/Pandoc/Class/IO.hs | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Text/Pandoc/Class/IO.hs b/src/Text/Pandoc/Class/IO.hs index 4c0d7b1ab..612ab7f51 100644 --- a/src/Text/Pandoc/Class/IO.hs +++ b/src/Text/Pandoc/Class/IO.hs @@ -188,7 +188,8 @@ openURL u Left (e :: HttpException) -> throwError $ PandocHttpError u (T.pack (show e)) #else - | otherwise = error "Text.Pandoc.Class.IO.openURL" + | otherwise = + throwError $ PandocHttpError u "pandoc was compiled without HTTP support" #endif -- | Read the lazy ByteString contents from a file path, raising an error on |
