1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-18 01:03:35 +00:00

update password generation service to use new crypto service

This commit is contained in:
Jacob Fink
2023-05-30 13:02:37 -04:00
parent 7a037724d5
commit ffc23bfcdb

View File

@@ -336,7 +336,7 @@ export class PasswordGenerationService implements PasswordGenerationServiceAbstr
} }
async getHistory(): Promise<GeneratedPasswordHistory[]> { async getHistory(): Promise<GeneratedPasswordHistory[]> {
const hasKey = await this.cryptoService.hasKey(); const hasKey = await this.cryptoService.hasUserKey();
if (!hasKey) { if (!hasKey) {
return new Array<GeneratedPasswordHistory>(); return new Array<GeneratedPasswordHistory>();
} }
@@ -356,7 +356,7 @@ export class PasswordGenerationService implements PasswordGenerationServiceAbstr
async addHistory(password: string): Promise<void> { async addHistory(password: string): Promise<void> {
// Cannot add new history if no key is available // Cannot add new history if no key is available
const hasKey = await this.cryptoService.hasKey(); const hasKey = await this.cryptoService.hasUserKey();
if (!hasKey) { if (!hasKey) {
return; return;
} }