Don't popup an error message when adding books if the cover is not a valid image

This commit is contained in:
Kovid Goyal 2010-05-06 17:46:35 -06:00
parent 1843490897
commit 56fc01dbac

View File

@ -1050,7 +1050,10 @@ class LibraryDatabase2(LibraryDatabase, SchemaUpgrade, CustomColumns):
mi.pubdate = utcnow() mi.pubdate = utcnow()
self.set_metadata(id, mi) self.set_metadata(id, mi)
if cover is not None: if cover is not None:
self.set_cover(id, cover) try:
self.set_cover(id, cover)
except:
traceback.print_exc()
return id return id