mirror of
https://github.com/zadam/trilium.git
synced 2025-11-12 16:25:51 +01:00
added migration to add excludeFromTreeMap for journal subtrees
This commit is contained in:
@@ -233,8 +233,6 @@ class Note extends AbstractEntity {
|
||||
}
|
||||
}
|
||||
|
||||
console.log("POJO update", pojo);
|
||||
|
||||
sql.upsert("note_contents", "noteId", pojo);
|
||||
|
||||
const hash = utils.hash(this.noteId + "|" + pojo.content.toString());
|
||||
|
||||
@@ -174,7 +174,7 @@ class Froca {
|
||||
return;
|
||||
}
|
||||
|
||||
const searchResultNoteIds = await server.get('special-notes/search-note/' + note.noteId);
|
||||
const searchResultNoteIds = await server.get('search-note/' + note.noteId);
|
||||
|
||||
if (!Array.isArray(searchResultNoteIds)) {
|
||||
throw new Error(`Search note ${note.noteId} failed: ${searchResultNoteIds}`);
|
||||
|
||||
@@ -4,7 +4,7 @@ const build = require('./build');
|
||||
const packageJson = require('../../package');
|
||||
const {TRILIUM_DATA_DIR} = require('./data_dir');
|
||||
|
||||
const APP_DB_VERSION = 183;
|
||||
const APP_DB_VERSION = 184;
|
||||
const SYNC_VERSION = 21;
|
||||
const CLIPPER_PROTOCOL_VERSION = "1.0";
|
||||
|
||||
|
||||
@@ -32,7 +32,14 @@ async function migrate() {
|
||||
// backup before attempting migration
|
||||
await backupService.backupNow("before-migration");
|
||||
|
||||
const currentDbVersion = parseInt(optionService.getOption('dbVersion'));
|
||||
const currentDbVersion = getDbVersion();
|
||||
|
||||
if (currentDbVersion < 183) {
|
||||
log.error("Direct migration from your current version is not supported. Please upgrade to the latest v0.47.X first and only then to this version.");
|
||||
|
||||
utils.crash();
|
||||
return;
|
||||
}
|
||||
|
||||
fs.readdirSync(resourceDir.MIGRATIONS_DIR).forEach(file => {
|
||||
const match = file.match(/([0-9]{4})__([a-zA-Z0-9_ ]+)\.(sql|js)/);
|
||||
|
||||
Reference in New Issue
Block a user