mirror of
https://github.com/zadam/trilium.git
synced 2025-03-01 14:22:32 +01:00
fix import
This commit is contained in:
parent
b3e66d5a83
commit
e70c862e72
@ -110,8 +110,10 @@ async function anonymize() {
|
|||||||
await db.run(`UPDATE attributes SET name = 'name' WHERE type = 'relation' AND name NOT IN (${builtinAttrs})`);
|
await db.run(`UPDATE attributes SET name = 'name' WHERE type = 'relation' AND name NOT IN (${builtinAttrs})`);
|
||||||
await db.run("UPDATE branches SET prefix = 'prefix' WHERE prefix IS NOT NULL");
|
await db.run("UPDATE branches SET prefix = 'prefix' WHERE prefix IS NOT NULL");
|
||||||
await db.run(`UPDATE options SET value = 'anonymized' WHERE name IN
|
await db.run(`UPDATE options SET value = 'anonymized' WHERE name IN
|
||||||
('documentId', 'documentSecret', 'encryptedDataKey', 'passwordVerificationHash',
|
('documentId', 'documentSecret', 'encryptedDataKey',
|
||||||
'passwordVerificationSalt', 'passwordDerivedKeySalt', 'username', 'syncServerHost', 'syncProxy')`);
|
'passwordVerificationHash', 'passwordVerificationSalt',
|
||||||
|
'passwordDerivedKeySalt', 'username', 'syncServerHost', 'syncProxy')
|
||||||
|
AND value != ''`);
|
||||||
await db.run("VACUUM");
|
await db.run("VACUUM");
|
||||||
|
|
||||||
await db.close();
|
await db.close();
|
||||||
|
@ -425,7 +425,7 @@ async function importTar(taskContext, fileBuffer, importRootNote) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
for (const noteId in createdNoteIds) { // now the noteIds are unique
|
for (const noteId in createdNoteIds) { // now the noteIds are unique
|
||||||
await noteService.scanForLinks(await repository.getNotes(noteId));
|
await noteService.scanForLinks(await repository.getNote(noteId));
|
||||||
|
|
||||||
if (!metaFile) {
|
if (!metaFile) {
|
||||||
// if there's no meta file then the notes are created based on the order in that tar file but that
|
// if there's no meta file then the notes are created based on the order in that tar file but that
|
||||||
|
@ -454,7 +454,7 @@ async function importZip(taskContext, fileBuffer, importRootNote) {
|
|||||||
});
|
});
|
||||||
|
|
||||||
for (const noteId in createdNoteIds) { // now the noteIds are unique
|
for (const noteId in createdNoteIds) { // now the noteIds are unique
|
||||||
await noteService.scanForLinks(await repository.getNotes(noteId));
|
await noteService.scanForLinks(await repository.getNote(noteId));
|
||||||
|
|
||||||
if (!metaFile) {
|
if (!metaFile) {
|
||||||
// if there's no meta file then the notes are created based on the order in that tar file but that
|
// if there's no meta file then the notes are created based on the order in that tar file but that
|
||||||
|
Loading…
x
Reference in New Issue
Block a user