mirror of
https://github.com/bitwarden/browser.git
synced 2024-11-23 11:56:00 +01:00
default type is login
This commit is contained in:
parent
4165a78277
commit
06f129e2c1
@ -85,8 +85,12 @@ export class BitwardenCsvImporter extends BaseImporter implements Importer {
|
||||
|
||||
const valueType = value.type != null ? value.type.toLowerCase() : null;
|
||||
switch (valueType) {
|
||||
case 'login':
|
||||
case null:
|
||||
case 'note':
|
||||
cipher.type = CipherType.SecureNote;
|
||||
cipher.secureNote = new SecureNoteView();
|
||||
cipher.secureNote.type = SecureNoteType.Generic;
|
||||
break;
|
||||
default:
|
||||
cipher.type = CipherType.Login;
|
||||
cipher.login = new LoginView();
|
||||
cipher.login.totp = this.getValueOrDefault(value.login_totp || value.totp);
|
||||
@ -95,13 +99,6 @@ export class BitwardenCsvImporter extends BaseImporter implements Importer {
|
||||
const uris = this.parseSingleRowCsv(value.login_uri || value.uri);
|
||||
cipher.login.uris = this.makeUriArray(uris);
|
||||
break;
|
||||
case 'note':
|
||||
cipher.type = CipherType.SecureNote;
|
||||
cipher.secureNote = new SecureNoteView();
|
||||
cipher.secureNote.type = SecureNoteType.Generic;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
result.ciphers.push(cipher);
|
||||
|
Loading…
Reference in New Issue
Block a user