1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-16 08:13:42 +00:00

service fixes for ciphers

This commit is contained in:
Kyle Spearrin
2017-10-14 14:27:14 -04:00
parent 5a1bf8299f
commit 355a58f67c
5 changed files with 179 additions and 162 deletions

View File

@@ -62,17 +62,18 @@ var CipherData = function (response, userId) {
this.name = response.data.Name;
this.notes = response.notes = response.data.Notes;
var constantsService = chrome.extension.getBackgroundPage().bg_constantsService;
switch (this.type) {
case 1: // cipherType.login
case constantsService.cipherType.login:
this.login = new LoginData2(response.data);
break;
case 2: // cipherType.secureNote
case constantsService.cipherType.secureNote:
this.secureNote = new SecureNoteData(response.data);
break;
case 3: // cipherType.card
case constantsService.cipherType.card:
this.card = new CardData(response.data);
break;
case 4: // cipherType.identity
case constantsService.cipherType.identity:
this.identity = new IdentityData(response.data);
break;
default: