1
0
mirror of https://github.com/bitwarden/browser synced 2026-01-06 18:43:25 +00:00

convert request/response models to jslib

This commit is contained in:
Kyle Spearrin
2018-01-08 14:45:34 -05:00
parent 5de4aad525
commit a78b8ec79c
38 changed files with 74 additions and 733 deletions

View File

@@ -1,34 +0,0 @@
import { FolderData } from '../data/folderData';
import { CipherString } from './cipherString';
import Domain from './domain';
class Folder extends Domain {
id: string;
name: CipherString;
constructor(obj?: FolderData, alreadyEncrypted: boolean = false) {
super();
if (obj == null) {
return;
}
this.buildDomainModel(this, obj, {
id: null,
name: null,
}, alreadyEncrypted, ['id']);
}
decrypt(): Promise<any> {
const model = {
id: this.id,
};
return this.decryptObj(model, {
name: null,
}, null);
}
}
export { Folder };
(window as any).Folder = Folder;