Skip to content

Commit

Permalink
Improve user list rendering perf by not resorting after every add (#2…
Browse files Browse the repository at this point in the history
…6282)

The call to UserList.add() was wrong and was passing "user.lastLogin"
as the sort argument which would cause the list to be resorted over and
over again for every added item after loading the next page of users.
  • Loading branch information
Vincent Petry authored and MorrisJobke committed Oct 10, 2016
1 parent 2dcd97b commit e3717fd
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion settings/js/users/users.js
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@ var UserList = {
if(UserList.has(user.name)) {
return true;
}
var $tr = UserList.add(user, user.lastLogin, false, user.backend);
var $tr = UserList.add(user, false);
trs.push($tr);
loadedUsers++;
});
Expand Down

0 comments on commit e3717fd

Please sign in to comment.