Only check for buggy IndexedDB once

This commit is contained in:
Thibaut 2015-01-03 18:22:12 -05:00
parent 04676edd54
commit eb58c01ee5

View file

@ -23,7 +23,9 @@ class app.DB
onOpenSuccess: (event) => onOpenSuccess: (event) =>
try try
db = event.target.result db = event.target.result
db.transaction(['docs', app.docs.all()[0].slug], 'readwrite').abort() # https://bugs.webkit.org/show_bug.cgi?id=136937 unless @checkedBuggyIDB
db.transaction(['docs', app.docs.all()[0].slug], 'readwrite').abort() # https://bugs.webkit.org/show_bug.cgi?id=136937
@checkedBuggyIDB = true
catch catch
try db.close() try db.close()
@onOpenError() @onOpenError()