diff options
author | Harmon <Harmon758@gmail.com> | 2020-02-07 05:56:27 -0600 |
---|---|---|
committer | Sebastian Thiel <sebastian.thiel@icloud.com> | 2020-02-08 10:55:50 +0800 |
commit | 6aa78cd3b969ede76a1a6e660962e898421d4ed8 (patch) | |
tree | 5eb2363fb7d727770da0b00c6a3fc081470cbd06 /git/refs/log.py | |
parent | e633cc009fe3dc8d29503b0d14532dc5e8c44cce (diff) | |
download | gitpython-6aa78cd3b969ede76a1a6e660962e898421d4ed8.tar.gz |
Remove checks for Python 2 and/or 3
Diffstat (limited to 'git/refs/log.py')
-rw-r--r-- | git/refs/log.py | 8 |
1 files changed, 1 insertions, 7 deletions
diff --git a/git/refs/log.py b/git/refs/log.py index 274660c5..d51c3458 100644 --- a/git/refs/log.py +++ b/git/refs/log.py @@ -2,7 +2,6 @@ import re import time from git.compat import ( - PY3, string_types, defenc ) @@ -35,12 +34,7 @@ class RefLogEntry(tuple): def __repr__(self): """Representation of ourselves in git reflog format""" - res = self.format() - if PY3: - return res - # repr must return a string, which it will auto-encode from unicode using the default encoding. - # This usually fails, so we encode ourselves - return res.encode(defenc) + return self.format() def format(self): """:return: a string suitable to be placed in a reflog file""" |