mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-05-05 01:23:38 +02:00
...
This commit is contained in:
parent
eeb8212f13
commit
a238a7184d
2 changed files with 6 additions and 1 deletions
|
|
@ -155,6 +155,9 @@ def store_file_stage2(self, needs_encoding, data, name, fname, proceed):
|
|||
req.onerror = def(event):
|
||||
proceed(_('Failed to store book data ({0}) with error: {1}').format(name, get_error_details(event)))
|
||||
|
||||
def clear_mathjax(self, proceed):
|
||||
self.idb.transaction(['mathjax'], 'readwrite').objectStore('mathjax').clear().onsuccess = proceed
|
||||
|
||||
def store_mathjax_file(self, name, xhr, proceed):
|
||||
data = xhr.response
|
||||
if not self.supports_blobs:
|
||||
|
|
|
|||
|
|
@ -261,7 +261,9 @@ def ensure_maths(self, proceed):
|
|||
if mathjax_info.version is MATHJAX_VERSION:
|
||||
return proceed()
|
||||
print('Upgrading MathJax, previous version:', mathjax_info.version)
|
||||
self.get_mathjax_manifest(mathjax_info, proceed)
|
||||
self.db.clear_mathjax(def():
|
||||
self.get_mathjax_manifest(mathjax_info, proceed)
|
||||
)
|
||||
)
|
||||
|
||||
def get_mathjax_manifest(self, mathjax_info, proceed):
|
||||
|
|
|
|||
Loading…
Reference in a new issue