generic notes fix

This commit is contained in:
Kyle Spearrin 2017-10-12 14:27:45 -04:00
parent 106e71fe54
commit 001a116c8b
1 changed files with 7 additions and 1 deletions

View File

@ -519,7 +519,11 @@
cipher.notes = value.extra && value.extra !== '' ? value.extra : null; cipher.notes = value.extra && value.extra !== '' ? value.extra : null;
} }
else if (cipher.type === contants.cipherType.secureNote) { else if (cipher.type === contants.cipherType.secureNote) {
if (value.extra.indexOf('NoteType:') === 0) { cipher.secureNote = {
type: 0
};
if (value.extra.indexOf('NoteType:') !== 0) {
// must be a generic note // must be a generic note
cipher.notes = value.extra && value.extra !== '' ? value.extra : null; cipher.notes = value.extra && value.extra !== '' ? value.extra : null;
} }
@ -532,12 +536,14 @@
if (typeParts[1] === 'Credit Card') { if (typeParts[1] === 'Credit Card') {
doFields = false; doFields = false;
cipher.type = contants.cipherType.card; cipher.type = contants.cipherType.card;
cipher.secureNote = null;
// TODO: handle card // TODO: handle card
cipher.card = {}; cipher.card = {};
} }
else if (typeParts[1] === 'Address') { else if (typeParts[1] === 'Address') {
doFields = false; doFields = false;
cipher.type = contants.cipherType.identity; cipher.type = contants.cipherType.identity;
cipher.secureNote = null;
// TODO: handle identity // TODO: handle identity
cipher.identity = {}; cipher.identity = {};
} }