mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
oops
This commit is contained in:
parent
d4b540b8cf
commit
9eee4a67b6
@ -292,7 +292,7 @@ def Book(options, logger, font_delta=0, header=None,
|
||||
raise ConversionError, 'Could not find the normal version of the ' + family + ' font'
|
||||
return book, fonts
|
||||
|
||||
def entity_to_unicode(self, match):
|
||||
def entity_to_unicode(match):
|
||||
ent = match.group(1)
|
||||
if ent.startswith(u'#x'):
|
||||
return unichr(int(ent[2:], 16))
|
||||
|
@ -51,11 +51,12 @@ class OPFReader(MetaInformation):
|
||||
if not role:
|
||||
role = elem.get('opf:role')
|
||||
if role == 'aut':
|
||||
au = elem.string.split(',')
|
||||
raw = self.ENTITY_PATTERN.sub(entity_to_unicode, elem.string)
|
||||
au = raw.split(',')
|
||||
ans = []
|
||||
for i in au:
|
||||
ans.extend(i.split('&'))
|
||||
return self.ENTITY_PATTERN.sub(entity_to_unicode, ans)
|
||||
return ans
|
||||
return None
|
||||
return property(doc=doc, fget=fget)
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user