mobile: always load notes on init

This commit is contained in:
ammarahm-ed
2023-04-26 08:53:27 +05:00
committed by Ammar Ahmed
parent 39d74e80a9
commit 536dead44d
2 changed files with 4 additions and 3 deletions

View File

@@ -86,8 +86,9 @@ async function getNextMonthlyReminderDate(
}
async function initDatabase(notes = true) {
if (db.isInitialized) return;
await db.initCollections();
if (!db.isInitialized) {
await db.initCollections();
}
if (notes) {
await db.notes?.init();
}

View File

@@ -31,8 +31,8 @@ export async function initDatabase() {
if (!db.isInitialized) {
// Only load collections in database.
await db.initCollections();
await db.notes.init();
}
await db.notes.init();
}
const StorageKeys = {