Update of src/PIL/YaffFontFile.py as per suggested
Co-authored-by: Andrew Murray <3112309+radarhere@users.noreply.github.com>
This commit is contained in:
parent
869e5874d8
commit
de223d88e8
@ -182,7 +182,7 @@ def load(
|
||||
:raises SyntaxError: If the file is not a valid YAFF font.
|
||||
"""
|
||||
if hasattr(font, "read"):
|
||||
data = font.read() # type: ignore[union-attr]
|
||||
data = font.read()
|
||||
if isinstance(data, bytes):
|
||||
text = data.decode("utf-8-sig")
|
||||
else:
|
||||
|
||||
Loading…
Reference in New Issue
Block a user