diff options
Diffstat (limited to 'Lib/tarfile.py')
-rw-r--r-- | Lib/tarfile.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/tarfile.py b/Lib/tarfile.py index ef6f1c7..97973fd 100644 --- a/Lib/tarfile.py +++ b/Lib/tarfile.py @@ -978,7 +978,7 @@ class TarInfo(object): info["name"] += "/" for key in ("name", "linkname", "uname", "gname"): - if type(info[key]) is unicode: + if isinstance(info[key], str): info[key] = info[key].encode(encoding, errors) return info |