Skip to content

Build your personal knowledge base with Trilium Notes

attempt to fix the duplicate issue

zadamcf3726289c94
diff --git a/package-lock.json b/package-lock.json
index 302bc51924..3fd371fc65 100644
--- a/package-lock.json
+++ b/package-lock.json
@@ -1,6 +1,6 @@
{
"name": "trilium",
- "version": "0.33.3",
+ "version": "0.33.4",
"lockfileVersion": 1,
"requires": true,
"dependencies": {
diff --git a/src/public/javascripts/services/tree.js b/src/public/javascripts/services/tree.js
index 4a3a236e77..7be6bff10a 100644
--- a/src/public/javascripts/services/tree.js
+++ b/src/public/javascripts/services/tree.js
@@ -630,7 +630,8 @@ async function createNote(node, parentNoteId, target, extraOptions = {}) {
extraClasses: await treeBuilder.getExtraClasses(noteEntity),
icon: await treeBuilder.getIcon(noteEntity),
folder: extraOptions.type === 'search',
- lazy: true
+ lazy: true,
+ key: utils.randomString(12) // this should prevent some "duplicate key" errors
};
if (target === 'after') {