forked from 0x2620/pandora
update sortSelect, sortKeys are now pre-filtered
This commit is contained in:
parent
0d5fda8921
commit
be702c5d43
1 changed files with 1 additions and 6 deletions
|
@ -15,12 +15,7 @@ pandora.ui.sortSelect = function(isNavigationView) {
|
|||
if (!pandora.user.ui.item) {
|
||||
items = [].concat(
|
||||
items,
|
||||
pandora.site.sortKeys.filter(function(key) {
|
||||
return Ox.getIndexById(items, key.id) == -1 && (
|
||||
!key.capability
|
||||
|| pandora.site.capabilities[key.capability][pandora.user.level]
|
||||
);
|
||||
}).map(function(key) {
|
||||
pandora.site.sortKeys.map(function(key) {
|
||||
return Ox.extend(Ox.clone(key), {
|
||||
title: 'Sort by ' + key.title
|
||||
});
|
||||
|
|
Loading…
Reference in a new issue