imported notes can reference root

This commit is contained in:
azivner 2018-11-18 11:19:50 +01:00
parent 3db2f6784d
commit 7691a59977

View file

@ -31,6 +31,11 @@ async function importTar(fileBuffer, parentNote) {
return "";
}
// we allow references to root and they don't need translation
if (origNoteId === 'root') {
return origNoteId;
}
if (!ctx.noteIdMap[origNoteId]) {
ctx.noteIdMap[origNoteId] = utils.newEntityId();
}