implemented consistency checks

This commit is contained in:
azivner
2017-12-14 22:16:26 -05:00
parent 581f406a24
commit d1329de760
9 changed files with 76 additions and 7 deletions

View File

@@ -73,7 +73,7 @@ async function protectNoteRecursively(noteId, dataKey, protect) {
await protectNote(note, dataKey, protect);
const children = await sql.getFlattenedResults("note_id", "SELECT note_id FROM notes_tree WHERE note_pid = ?", [noteId]);
const children = await sql.getFlattenedResults("SELECT note_id FROM notes_tree WHERE note_pid = ?", [noteId]);
for (const childNoteId of children) {
await protectNoteRecursively(childNoteId, dataKey, protect);