mirror of
https://github.com/owncloudarchive/contacts.git
synced 2025-01-30 19:52:17 +01:00
Don't sort rows twice :P
This commit is contained in:
parent
bb3012fa0f
commit
6c6d2aca8e
@ -2288,16 +2288,6 @@ OC.Contacts = OC.Contacts || {};
|
||||
.localeCompare($(b).find('td.name').text().toUpperCase());
|
||||
});
|
||||
}
|
||||
rows.sort(function(a, b) {
|
||||
// 10 (TEN!) times faster than using jQuery!
|
||||
if(a.firstElementChild) {
|
||||
return a.firstElementChild.textContent.trim().toUpperCase()
|
||||
.localeCompare(b.firstElementChild.textContent.trim().toUpperCase());
|
||||
} else {
|
||||
return $(a).find('.nametext').text().toUpperCase()
|
||||
.localeCompare($(b).find('td.name').text().toUpperCase());
|
||||
}
|
||||
});
|
||||
this.$contactList.prepend(rows);
|
||||
//console.timeEnd('sort');
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user