mirror of
https://github.com/bitwarden/browser
synced 2025-12-18 01:03:35 +00:00
call into load method
This commit is contained in:
@@ -25,7 +25,7 @@ import { CipherView } from '../../models/view/cipherView';
|
||||
import { FieldView } from '../../models/view/fieldView';
|
||||
import { LoginUriView } from '../../models/view/loginUriView';
|
||||
|
||||
export class ViewComponent implements OnChanges, OnDestroy {
|
||||
export class ViewComponent implements OnDestroy {
|
||||
@Input() cipherId: string;
|
||||
@Output() onEditCipher = new EventEmitter<CipherView>();
|
||||
|
||||
@@ -48,7 +48,11 @@ export class ViewComponent implements OnChanges, OnDestroy {
|
||||
protected i18nService: I18nService, protected analytics: Angulartics2,
|
||||
protected auditService: AuditService) { }
|
||||
|
||||
async ngOnChanges() {
|
||||
ngOnDestroy() {
|
||||
this.cleanUp();
|
||||
}
|
||||
|
||||
async load() {
|
||||
this.cleanUp();
|
||||
|
||||
const cipher = await this.cipherService.get(this.cipherId);
|
||||
@@ -67,10 +71,6 @@ export class ViewComponent implements OnChanges, OnDestroy {
|
||||
}
|
||||
}
|
||||
|
||||
ngOnDestroy() {
|
||||
this.cleanUp();
|
||||
}
|
||||
|
||||
edit() {
|
||||
this.onEditCipher.emit(this.cipher);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user