mirror of
https://github.com/tachiyomiorg/website.git
synced 2024-12-21 23:51:58 +01:00
refactored sort filter (#652)
since extensions are already sorted, just reverse them if DESC selected
This commit is contained in:
parent
b6f85fc9a7
commit
7555e6f725
@ -123,9 +123,7 @@ export default {
|
|||||||
);
|
);
|
||||||
|
|
||||||
if (filters.sort && filters.sort === "Descending") {
|
if (filters.sort && filters.sort === "Descending") {
|
||||||
filteredGroup = filteredGroup.sort((a, b) => {
|
filteredGroup = filteredGroup.reverse();
|
||||||
return a.name < b.name ? 1 : a.name > b.name ? -1 : 0;
|
|
||||||
});
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if (filteredGroup.length) {
|
if (filteredGroup.length) {
|
||||||
|
Loading…
Reference in New Issue
Block a user