summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Crypto/Tox.hs3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Crypto/Tox.hs b/src/Crypto/Tox.hs
index bd4cdfba..d418f504 100644
--- a/src/Crypto/Tox.hs
+++ b/src/Crypto/Tox.hs
@@ -582,7 +582,8 @@ data TransportCrypto = TransportCrypto
582 } 582 }
583 583
584getPublicKey :: S.Get PublicKey 584getPublicKey :: S.Get PublicKey
585getPublicKey = throwCryptoError . publicKey <$> S.getBytes 32 585getPublicKey = eitherCryptoError . publicKey <$> S.getBytes 32
586 >>= either (fail . show) return
586 587
587putPublicKey :: PublicKey -> S.Put 588putPublicKey :: PublicKey -> S.Put
588putPublicKey bs = S.putByteString $ BA.convert bs 589putPublicKey bs = S.putByteString $ BA.convert bs