1
0
mirror of https://github.com/bitwarden/browser synced 2025-12-19 01:33:33 +00:00

bug fix + added launch time to view component (#178)

This commit is contained in:
Addison Beck
2020-09-23 13:53:43 -04:00
committed by GitHub
parent 26d40d4c43
commit b5cc5409ff
2 changed files with 7 additions and 2 deletions

View File

@@ -57,7 +57,8 @@ class Ciphers {
}
getLastLaunched() {
const sortedCiphers = this.ciphers.sort((x, y) => y.localData?.lastLaunched?.valueOf() - x.localData?.lastLaunched?.valueOf());
const usedCiphers = this.ciphers.filter(cipher => cipher.localData?.lastLaunched)
const sortedCiphers = usedCiphers.sort((x, y) => y.localData.lastLaunched.valueOf() - x.localData.lastLaunched.valueOf());
return sortedCiphers[0];
}