]> www.wagner.pp.ru Git - oss/ctypescrypto.git/blobdiff - ctypescrypto/cipher.py
Fixes some style. Improved tests coverage for bio,oid,digest and cipher. Prepare...
[oss/ctypescrypto.git] / ctypescrypto / cipher.py
index 332272570f824c9830dbe003a09c123f138b5aa7..815a42541897232853a0721b9fea12be9d42217b 100644 (file)
@@ -171,7 +171,7 @@ class Cipher:
                """
                if self.cipher_finalized :
                        raise CipherError("No updates allowed")
-               if type(data) != type(""):
+               if not isinstance(data,str):
                        raise TypeError("A string is expected")
                if len(data) <= 0:
                        return ""