1
0
mirror of https://github.com/bitwarden/browser synced 2026-01-06 10:33:57 +00:00

add missing types to models

This commit is contained in:
Kyle Spearrin
2017-11-13 16:21:45 -05:00
parent bed28aebaa
commit 4664c783f2
5 changed files with 17 additions and 7 deletions

View File

@@ -1,7 +1,9 @@
import { Folder } from '../domain/folder';
class FolderRequest {
name: string;
constructor(folder: any) { // TODO: folder type
constructor(folder: Folder) {
this.name = folder.name ? folder.name.encryptedString : null;
}
}

View File

@@ -1,19 +1,21 @@
import { DeviceRequest } from './deviceRequest';
class TokenRequest {
email: string;
masterPasswordHash: string;
token: string;
provider: number;
remember: boolean;
device?: any;
device?: DeviceRequest;
constructor(email: string, masterPasswordHash: string, provider: number,
token: string, remember: boolean, device?: any) {
token: string, remember: boolean, device?: DeviceRequest) {
this.email = email;
this.masterPasswordHash = masterPasswordHash;
this.token = token;
this.provider = provider;
this.remember = remember;
this.device = device ? device : null;
this.device = device != null ? device : null;
}
toIdentityToken() {