We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent c5d372f commit b3f4f13Copy full SHA for b3f4f13
src/database/client/db.ts
@@ -201,7 +201,8 @@ export class DatabaseManager {
201
const dbName = 'lobechat';
202
203
// make db as web worker if worker is available
204
- if (typeof Worker !== 'undefined') {
+ // https://github.com/lobehub/lobe-chat/issues/5785
205
+ if (typeof Worker !== 'undefined' && typeof navigator.locks !== 'undefined') {
206
db = await initPgliteWorker({
207
dbName,
208
fsBundle: fsBundle as Blob,
0 commit comments