PM-9632 added MP reprompt check to edit button in view-v2 (#10104)
This commit is contained in:
parent
81a3dce774
commit
b7e102dd6d
|
@ -102,7 +102,20 @@ export class ViewV2Component {
|
||||||
return await cipher.decrypt(await this.cipherService.getKeyForCipherKeyDecryption(cipher));
|
return await cipher.decrypt(await this.cipherService.getKeyForCipherKeyDecryption(cipher));
|
||||||
}
|
}
|
||||||
|
|
||||||
editCipher() {
|
async checkForPasswordReprompt() {
|
||||||
|
this.passwordReprompted =
|
||||||
|
this.passwordReprompted ||
|
||||||
|
(await this.passwordRepromptService.passwordRepromptCheck(this.cipher));
|
||||||
|
if (!this.passwordReprompted) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
async editCipher() {
|
||||||
|
if (!(await this.checkForPasswordReprompt())) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
if (this.cipher.isDeleted) {
|
if (this.cipher.isDeleted) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -113,10 +126,7 @@ export class ViewV2Component {
|
||||||
}
|
}
|
||||||
|
|
||||||
delete = async (): Promise<boolean> => {
|
delete = async (): Promise<boolean> => {
|
||||||
this.passwordReprompted =
|
if (!(await this.checkForPasswordReprompt())) {
|
||||||
this.passwordReprompted ||
|
|
||||||
(await this.passwordRepromptService.passwordRepromptCheck(this.cipher));
|
|
||||||
if (!this.passwordReprompted) {
|
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue