diff options
author | Jon Dufresne <jon.dufresne@gmail.com> | 2017-11-02 06:30:07 -0700 |
---|---|---|
committer | Jon Dufresne <jon.dufresne@gmail.com> | 2018-11-03 03:21:49 -0700 |
commit | 5089cc275e6077a070017587001c22e490995d47 (patch) | |
tree | eb8e52047d04f36f1a9562fa47e0a853ffab79eb /redis/exceptions.py | |
parent | 7a0e4c7f99463c79b456a48837b5687072e1485d (diff) | |
download | redis-py-5089cc275e6077a070017587001c22e490995d47.tar.gz |
Use unicode literals throughout project
Remove workaround for handling unicode with older Pythons.
Diffstat (limited to 'redis/exceptions.py')
-rw-r--r-- | redis/exceptions.py | 11 |
1 files changed, 0 insertions, 11 deletions
diff --git a/redis/exceptions.py b/redis/exceptions.py index a8518c7..44ab6f7 100644 --- a/redis/exceptions.py +++ b/redis/exceptions.py @@ -1,21 +1,10 @@ "Core exceptions raised by the Redis client" -from redis._compat import unicode class RedisError(Exception): pass -# python 2.5 doesn't implement Exception.__unicode__. Add it here to all -# our exception types -if not hasattr(RedisError, '__unicode__'): - def __unicode__(self): - if isinstance(self.args[0], unicode): - return self.args[0] - return unicode(self.args[0]) - RedisError.__unicode__ = __unicode__ - - class AuthenticationError(RedisError): pass |