mirror of
https://github.com/streetwriters/notesnook.git
synced 2025-12-21 14:09:34 +01:00
fix: init trash & monographs after notes
This commit is contained in:
@@ -70,6 +70,15 @@ class Database {
|
||||
this.syncer.stopAutoSync();
|
||||
this.disconnectSSE();
|
||||
});
|
||||
EV.subscribe(EVENTS.databaseCollectionInitiated, async (collectionName) => {
|
||||
switch (collectionName) {
|
||||
case "notes": {
|
||||
await this.monographs.init();
|
||||
await this.trash.init();
|
||||
break;
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
this.session = new Session(this.storage);
|
||||
await this._validate();
|
||||
@@ -103,7 +112,6 @@ class Database {
|
||||
|
||||
this.trash = new Trash(this);
|
||||
|
||||
await this.trash.cleanup();
|
||||
await this.settings.init();
|
||||
await this.outbox.init();
|
||||
await this.user.init();
|
||||
|
||||
Reference in New Issue
Block a user