Fix regression that broke MOBI output in the GUI

This commit is contained in:
Kovid Goyal 2011-01-21 14:43:43 -07:00
parent ff97a9279f
commit b27a2625cb

View File

@ -1541,7 +1541,10 @@ class MobiWriter(object):
exth.write(data)
nrecs += 1
if term == 'rights' :
try:
rights = unicode(oeb.metadata.rights[0]).encode('utf-8')
except:
rights = 'Unknown'
exth.write(pack('>II', EXTH_CODES['rights'], len(rights) + 8))
exth.write(rights)