~alcinnz/hurl

5116153eb6ea1dd9cae8f7aea4597207a35d1516 — Adrian Cochrane 4 years ago a0a0249
Silence encoding errors, as it's a nuisance for encoding sniffing.

TODO: This didn't make it into the previous release.
1 files changed, 1 insertions(+), 1 deletions(-)

M src/Network/URI/Charset.hs
M src/Network/URI/Charset.hs => src/Network/URI/Charset.hs +1 -1
@@ 38,7 38,7 @@ convertCharset "utf-32" = decodeUtf32LEWith replaceChar
convertCharset charset = -- FIXME Is this the best fallback for unsupported charsets?
    trace ("Unsupported text encoding" ++ charset) $ decodeUtf8With replaceChar

replaceChar error _ = trace error $ Just '�'
replaceChar _ _ = Just '�'

-- | Lists all charsets supported by convertCharset
charsets :: [Text]