mirror of
https://github.com/bitwarden/browser.git
synced 2024-09-18 02:41:15 +02:00
rename sorts
This commit is contained in:
parent
65842a3dba
commit
ea1ef54c95
@ -457,7 +457,7 @@ var bg_isBackground = true,
|
|||||||
|
|
||||||
menuOptionsLoaded = [];
|
menuOptionsLoaded = [];
|
||||||
bg_cipherService.getAllDecryptedForDomain(tabDomain).then(function (logins) {
|
bg_cipherService.getAllDecryptedForDomain(tabDomain).then(function (logins) {
|
||||||
logins.sort(bg_cipherService.sortLoginsByLastUsedThenName);
|
logins.sort(bg_cipherService.sortCiphersByLastUsedThenName);
|
||||||
|
|
||||||
if (contextMenuEnabled) {
|
if (contextMenuEnabled) {
|
||||||
for (var i = 0; i < logins.length; i++) {
|
for (var i = 0; i < logins.length; i++) {
|
||||||
|
@ -576,10 +576,10 @@ function initCipherService() {
|
|||||||
return deferred.promise;
|
return deferred.promise;
|
||||||
};
|
};
|
||||||
|
|
||||||
CipherService.prototype.sortLoginsByLastUsed = sortLoginsByLastUsed;
|
CipherService.prototype.sortCiphersByLastUsed = sortCiphersByLastUsed;
|
||||||
|
|
||||||
CipherService.prototype.sortLoginsByLastUsedThenName = function (a, b) {
|
CipherService.prototype.sortCiphersByLastUsedThenName = function (a, b) {
|
||||||
var result = sortLoginsByLastUsed(a, b);
|
var result = sortCiphersByLastUsed(a, b);
|
||||||
if (result !== 0) {
|
if (result !== 0) {
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
@ -597,7 +597,7 @@ function initCipherService() {
|
|||||||
return 0;
|
return 0;
|
||||||
};
|
};
|
||||||
|
|
||||||
function sortLoginsByLastUsed(a, b) {
|
function sortCiphersByLastUsed(a, b) {
|
||||||
var aLastUsed = a.localData && a.localData.lastUsedDate ? a.localData.lastUsedDate : null;
|
var aLastUsed = a.localData && a.localData.lastUsedDate ? a.localData.lastUsedDate : null;
|
||||||
var bLastUsed = b.localData && b.localData.lastUsedDate ? b.localData.lastUsedDate : null;
|
var bLastUsed = b.localData && b.localData.lastUsedDate ? b.localData.lastUsedDate : null;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user