Remove now unnecessary Python 2 code path

This commit is contained in:
Nikolaus Waxweiler 2019-08-27 15:54:29 +01:00
parent 63fb3fb881
commit 811316cd3a

View File

@ -390,13 +390,7 @@ class NameRecord(object):
"""
return tobytes(self.string, encoding=self.getEncoding(), errors=errors)
def toStr(self, errors='strict'):
if str == bytes:
# python 2
return self.toBytes(errors)
else:
# python 3
return self.toUnicode(errors)
toStr = toUnicode
def toXML(self, writer, ttFont):
try: