This commit is contained in:
Kovid Goyal 2024-08-31 15:46:41 +05:30
parent 671d5cec4b
commit ef5bab65e8
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -106,7 +106,7 @@ class OEBReader:
elem.tag = OPF(barename(elem.tag))
nsmap.update(OPF2_NSMAP)
attrib = dict(opf.attrib)
if xmlns := attrib.pop('xmlns:'):
if xmlns := attrib.pop('xmlns:', None):
attrib['xmlns'] = xmlns
nroot = etree.Element(OPF('package'),
nsmap={None: OPF2_NS}, attrib=attrib)