cannot edit note title when not in protected session

This commit is contained in:
azivner
2018-12-27 20:22:33 +01:00
parent d4db265fd9
commit 35bc1421f1
6 changed files with 29 additions and 1 deletions

View File

@@ -109,6 +109,10 @@ function onNoteChange(func) {
async function saveNote() {
const note = getCurrentNote();
if (note.isProtected && !protectedSessionHolder.isProtectedSessionAvailable()) {
return;
}
note.title = $noteTitle.val();
note.content = getCurrentNoteContent(note);
@@ -223,6 +227,8 @@ async function loadNoteDetail(noteId) {
return;
}
$noteTitle.removeAttr("readonly"); // this can be set by protected session service
await getComponent(currentNote.type).show();
}
finally {