mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-02-08 10:33:44 +00:00
fix(y-indexeddb): un-track doc when destroy (#3358)
This commit is contained in:
@@ -239,8 +239,7 @@ export const createIndexedDBProvider = (
|
||||
return destroyHandlerMap.get(doc)!;
|
||||
}
|
||||
const fn = async function handleDestroy() {
|
||||
const db = await dbPromise;
|
||||
db.close();
|
||||
unTrackDoc(doc.guid, doc);
|
||||
};
|
||||
destroyHandlerMap.set(doc, fn);
|
||||
return fn;
|
||||
|
||||
Reference in New Issue
Block a user