mirror of
https://github.com/python-pillow/Pillow.git
synced 2024-12-26 01:46:18 +03:00
Remove leftover Python 2 compatibility shim
In Python 3, __str__ should not return bytes.
This commit is contained in:
parent
22a6738a81
commit
d57d02e827
|
@ -241,15 +241,11 @@ class PdfName:
|
|||
result.extend(make_bytes("#%02X" % b))
|
||||
return bytes(result)
|
||||
|
||||
__str__ = __bytes__
|
||||
|
||||
|
||||
class PdfArray(list):
|
||||
def __bytes__(self):
|
||||
return b"[ " + b" ".join(pdf_repr(x) for x in self) + b" ]"
|
||||
|
||||
__str__ = __bytes__
|
||||
|
||||
|
||||
class PdfDict(collections.UserDict):
|
||||
def __setattr__(self, key, value):
|
||||
|
|
Loading…
Reference in New Issue
Block a user