mirror of
https://github.com/bitwarden/browser
synced 2025-12-17 16:53:34 +00:00
Revert "make getAllDecrypted synchronous"
This reverts commit 51ee0b065a.
This commit is contained in:
@@ -181,10 +181,13 @@ export class CipherService implements CipherServiceAbstraction {
|
||||
throw new Error('No key.');
|
||||
}
|
||||
|
||||
const promises: any[] = [];
|
||||
const ciphers = await this.getAll();
|
||||
for (let i = 0; i < ciphers.length; i++) {
|
||||
decCiphers.push(await ciphers[i].decrypt());
|
||||
}
|
||||
ciphers.forEach((cipher) => {
|
||||
promises.push(cipher.decrypt().then((c) => decCiphers.push(c)));
|
||||
});
|
||||
|
||||
await Promise.all(promises);
|
||||
decCiphers.sort(this.getLocaleSortingFunction());
|
||||
this.decryptedCipherCache = decCiphers;
|
||||
return this.decryptedCipherCache;
|
||||
|
||||
Reference in New Issue
Block a user