mirror of
https://github.com/zadam/trilium.git
synced 2024-12-25 00:34:08 +08:00
fix cloning already existing (deleted) node
This commit is contained in:
parent
fe81fcf332
commit
0dc142ff06
1 changed files with 1 additions and 1 deletions
|
@ -93,7 +93,7 @@ router.put('/:childNoteId/clone-to/:parentNoteId', auth.checkApiAuth, async (req
|
|||
const prefix = req.body.prefix;
|
||||
const sourceId = req.headers.source_id;
|
||||
|
||||
const existing = await sql.getFirstValue('SELECT * FROM notes_tree WHERE note_id = ? AND parent_note_id = ?', [childNoteId, parentNoteId]);
|
||||
const existing = await sql.getFirst('SELECT * FROM notes_tree WHERE note_id = ? AND parent_note_id = ?', [childNoteId, parentNoteId]);
|
||||
|
||||
if (existing && !existing.is_deleted) {
|
||||
return res.send({
|
||||
|
|
Loading…
Reference in a new issue