mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
fixes
This commit is contained in:
parent
995ebbf577
commit
67663fba50
@ -480,7 +480,7 @@ async function eraseDeletedNotes() {
|
||||
SET content = NULL,
|
||||
utcDateModified = '${utcNowDateTime}'
|
||||
WHERE noteRevisionId IN
|
||||
(SELECT noteRevisionId FROM note_revisions WHERE isErased = 0 AND noteId IN ((???)))`, noteIdsToErase);
|
||||
(SELECT noteRevisionId FROM note_revisions WHERE isErased = 0 AND noteId IN (???))`, noteIdsToErase);
|
||||
|
||||
await sql.executeMany(`
|
||||
UPDATE note_revisions
|
||||
@ -530,7 +530,7 @@ async function duplicateNote(noteId, parentNoteId) {
|
||||
|
||||
sqlInit.dbReady.then(() => {
|
||||
// first cleanup kickoff 5 minutes after startup
|
||||
setTimeout(cls.wrap(eraseDeletedNotes), 5 * 60 * 1000);
|
||||
setTimeout(cls.wrap(eraseDeletedNotes), 0 * 60 * 1000);
|
||||
|
||||
setInterval(cls.wrap(eraseDeletedNotes), 4 * 3600 * 1000);
|
||||
});
|
||||
|
@ -173,9 +173,11 @@ async function isDbUpToDate() {
|
||||
}
|
||||
|
||||
async function dbInitialized() {
|
||||
await optionService.setOption('initialized', 'true');
|
||||
if (!await isDbInitialized()) {
|
||||
await optionService.setOption('initialized', 'true');
|
||||
|
||||
await initDbConnection();
|
||||
await initDbConnection();
|
||||
}
|
||||
}
|
||||
|
||||
dbReady.then(async () => {
|
||||
|
Loading…
x
Reference in New Issue
Block a user