diff options
author | Sybren A. Stüvel <sybren@stuvel.eu> | 2016-01-27 17:38:32 +0100 |
---|---|---|
committer | Sybren A. Stüvel <sybren@stuvel.eu> | 2016-01-27 17:38:32 +0100 |
commit | 48a7c7fb738454bd57f508014dc98157c142e941 (patch) | |
tree | f7d35eaf0db79de8b2e257fb8e6f486d93a8edfa | |
parent | bd6ab7a47237634a93a3093b7a19133b029101cf (diff) | |
download | rsa-git-48a7c7fb738454bd57f508014dc98157c142e941.tar.gz |
Removed some compatibility code for Python 2.6
-rw-r--r-- | rsa/_compat.py | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/rsa/_compat.py b/rsa/_compat.py index 6fb9b62..383ad24 100644 --- a/rsa/_compat.py +++ b/rsa/_compat.py @@ -64,13 +64,6 @@ except NameError: b = byte_literal -try: - # Python 2.6 or higher. - bytes_type = bytes -except NameError: - # Python 2.5 - bytes_type = str - # To avoid calling b() multiple times in tight loops. ZERO_BYTE = b('\x00') EMPTY_BYTE = b('') @@ -85,7 +78,7 @@ def is_bytes(obj): :returns: ``True`` if ``value`` is a byte string; ``False`` otherwise. """ - return isinstance(obj, bytes_type) + return isinstance(obj, bytes) def is_integer(obj): |