mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Clear the format metadata cache for a book when a format is deleted.
This commit is contained in:
parent
137093ebb9
commit
d967da0b30
@ -1333,6 +1333,7 @@ class LibraryDatabase2(LibraryDatabase, SchemaUpgrade, CustomColumns):
|
||||
def remove_format(self, index, format, index_is_id=False, notify=True,
|
||||
commit=True, db_only=False):
|
||||
id = index if index_is_id else self.id(index)
|
||||
del self.format_metadata_cache[id]
|
||||
name = self.conn.get('SELECT name FROM data WHERE book=? AND format=?', (id, format), all=False)
|
||||
if name:
|
||||
if not db_only:
|
||||
|
Loading…
x
Reference in New Issue
Block a user