Correct fromText

This commit is contained in:
Rene Vergara 2024-02-06 11:47:39 -06:00
parent 49bceb5f14
commit 309dd06a2e
Signed by: pitmutt
GPG key ID: 65122AD495A7F5B2

View file

@ -83,7 +83,7 @@ toBytes (HexString bs) = BS16.decodeLenient bs
-- | Reads a human-readable hex string into a `HexString`
fromText :: T.Text -> HexString
fromText = hexString . TE.encodeUtf8
fromText = hexString . BS16.decodeLenient . TE.encodeUtf8
-- | Access to a 'T.Text' representation of the 'HexString'
toText :: HexString -> T.Text