sony driver: fix missing mime attribute when adding a new book

This commit is contained in:
Charles Haley 2010-05-21 11:30:05 +01:00
parent a1e85abb2f
commit 57ab9f1ba0

View file

@ -428,8 +428,8 @@ def update_text_record(self, record, book, path, bl_index):
mime = MIME_MAP.get(ext, None)
if mime is None:
mime = guess_type('a.'+ext)[0]
if mime is not None:
record.set('mime', mime)
if mime is not None:
record.set('mime', mime)
if 'sourceid' not in record.attrib:
record.set('sourceid', '1')
if 'id' not in record.attrib: