mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Only set language in MOBI metadata is it is not null
This commit is contained in:
parent
2ac771e1dc
commit
7f133692ef
@ -400,7 +400,8 @@ class MetadataUpdater(object):
|
|||||||
if getattr(self, 'exth', None) is None:
|
if getattr(self, 'exth', None) is None:
|
||||||
raise MobiError('No existing EXTH record. Cannot update metadata.')
|
raise MobiError('No existing EXTH record. Cannot update metadata.')
|
||||||
|
|
||||||
self.record0[92:96] = iana2mobi(mi.language)
|
if not mi.is_null('language'):
|
||||||
|
self.record0[92:96] = iana2mobi(mi.language)
|
||||||
self.create_exth(exth=exth, new_title=mi.title)
|
self.create_exth(exth=exth, new_title=mi.title)
|
||||||
|
|
||||||
# Fetch updated timestamp, cover_record, thumbnail_record
|
# Fetch updated timestamp, cover_record, thumbnail_record
|
||||||
|
Loading…
x
Reference in New Issue
Block a user