sync fixes

This commit is contained in:
azivner
2017-11-16 22:18:25 -05:00
parent b2d1ca1c28
commit e53926738c
10 changed files with 26 additions and 27 deletions

View File

@@ -33,7 +33,7 @@ router.get('/', auth.checkApiAuth, async (req, res, next) => {
note.children = [];
if (!note.note_pid) {
if (note.note_pid === "root") {
root_notes.push(note);
}
@@ -41,7 +41,7 @@ router.get('/', auth.checkApiAuth, async (req, res, next) => {
}
for (const note of notes) {
if (note.note_pid !== "") {
if (note.note_pid !== "root") {
const parent = notes_map[note.note_pid];
if (!parent) {