mirror of
https://github.com/bitwarden/browser
synced 2025-12-12 14:23:32 +00:00
28 lines
569 B
TypeScript
28 lines
569 B
TypeScript
import { SecureNoteType } from '../../enums/secureNoteType.enum';
|
|
|
|
import { SecureNoteData } from '../data/secureNoteData';
|
|
|
|
import Domain from './domain';
|
|
|
|
class SecureNote extends Domain {
|
|
type: SecureNoteType;
|
|
|
|
constructor(obj?: SecureNoteData, alreadyEncrypted: boolean = false) {
|
|
super();
|
|
if (obj == null) {
|
|
return;
|
|
}
|
|
|
|
this.type = obj.type;
|
|
}
|
|
|
|
decrypt(orgId: string): any {
|
|
return {
|
|
type: this.type,
|
|
};
|
|
}
|
|
}
|
|
|
|
export { SecureNote };
|
|
(window as any).SecureNote = SecureNote;
|