Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

reverse clearData order #14

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

reverse clearData order #14

wants to merge 1 commit into from

Conversation

YousefED
Copy link

I'm encountering a weird race issue when calling clearData

  • My call to clearData gets called, but results in a refresh of the current page (which is caused by the idb blocked handler)
  • onversionchange never gets called

My assumption is that because destroy() calls idb.close, the onversionchange handler is never called. but at the same time, the idb handle is not really "closed" yet when we call deleteDB.

My solution would be to switch the order of the calls, see PR

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant