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

pouchdb-authentication is not working in a webworker #267

Open
hans-helmut opened this issue Jan 5, 2021 · 0 comments
Open

pouchdb-authentication is not working in a webworker #267

hans-helmut opened this issue Jan 5, 2021 · 0 comments

Comments

@hans-helmut
Copy link

Copying pouchdb.js (7.2.2), pouchdb.authentication.js (1.1.3) and some code together into a webworker script does not work, PouchDB.logIn() keeps undefined.

I just replaced all "window" with "self" within pouchdb.authentication.js and then it works. In my opinion the root-cause is the following code in src/index.js, but I am not able to build pouchdb.authentication.js for testing.


if (typeof window !== 'undefined' && window.PouchDB) {
  window.PouchDB.plugin(plugin);
}
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

No branches or pull requests

1 participant