misc: update xml storage to check bytes (#36515)

This commit is contained in:
Frédéric Péters 2019-11-12 15:20:47 +01:00
parent 90fdf2c398
commit 5f1629a898
1 changed files with 1 additions and 1 deletions

View File

@ -30,7 +30,7 @@ class XmlStorableObject(StorableObject):
def storage_load(cls, fd):
first_byte = fd.read(1)
fd.seek(0)
if first_byte == '<':
if first_byte == b'<':
return cls.import_from_xml(fd, include_id=True)
else:
return StorableObject.storage_load(fd)