diff --git a/CliClient/app/command-todo.js b/CliClient/app/command-todo.js index 3938edc25..0bba443c1 100644 --- a/CliClient/app/command-todo.js +++ b/CliClient/app/command-todo.js @@ -35,8 +35,11 @@ class Command extends BaseCommand { }; if (action == 'toggle') { - toSave.todo_completed = note.todo_completed ? 0 : time.unixMs(); - if (!note.is_todo) toSave.is_todo = 1; + if (!note.is_todo) { + toSave = Note.toggleIsTodo(note); + } else { + toSave.todo_completed = note.todo_completed ? 0 : time.unixMs(); + } } else if (action == 'clear') { toSave.is_todo = 0; } diff --git a/CliClient/locales/fr_FR.po b/CliClient/locales/fr_FR.po index 30888c1d0..c6829f56e 100644 --- a/CliClient/locales/fr_FR.po +++ b/CliClient/locales/fr_FR.po @@ -14,8 +14,6 @@ msgstr "" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "X-Generator: Poedit 2.0.3\n" -"POT-Creation-Date: \n" -"PO-Revision-Date: \n" msgid "No notebook selected." msgstr "Aucun carnet n'est sélectionné." diff --git a/ReactNativeClient/lib/models/note.js b/ReactNativeClient/lib/models/note.js index 6e4eb2f57..80a94f763 100644 --- a/ReactNativeClient/lib/models/note.js +++ b/ReactNativeClient/lib/models/note.js @@ -272,10 +272,8 @@ class Note extends BaseItem { let output = Object.assign({}, note); output.is_todo = output.is_todo ? 0 : 1; - if (!output.is_todo) { - output.todo_due = 0; - output.todo_completed = 0; - } + output.todo_due = 0; + output.todo_completed = 0; return output; }