Skip to content

Build your personal knowledge base with Trilium Notes

def value

zadam3d15aeae5822
diff --git a/src/services/cloning.js b/src/services/cloning.js
index ed1c242141..4d66033732 100644
--- a/src/services/cloning.js
+++ b/src/services/cloning.js
@@ -7,7 +7,7 @@ const BBranch = require('../becca/entities/bbranch');
const becca = require("../becca/becca");
const log = require("./log");
-function cloneNoteToParentNote(noteId, parentNoteId, prefix) {
+function cloneNoteToParentNote(noteId, parentNoteId, prefix = null) {
if (!(noteId in becca.notes) || !(parentNoteId in becca.notes)) {
return { success: false, message: 'Note cannot be cloned because either the cloned note or the intended parent is deleted.' };
}