appstore: fix popularity sorting

This commit is contained in:
Alexandre Aubin 2023-09-26 13:36:48 +02:00
parent a79cb310ff
commit 8659c2f089
2 changed files with 2 additions and 2 deletions

View file

@ -239,7 +239,7 @@
}
else if (sortBy === "popularity") {
toSort.sort(function(a, b) {
return a.dataset.stars < b.dataset.stars ? 1 : -1;
return parseInt(a.dataset.stars) < parseInt(b.dataset.stars) ? 1 : -1;
});
}
else if (sortBy === "") {

View file

@ -211,7 +211,7 @@
}
else if (sortBy === "popularity") {
toSort.sort(function(a, b) {
return a.dataset.stars < b.dataset.stars ? 1 : -1;
return parseInt(a.dataset.stars) < parseInt(b.dataset.stars) ? 1 : -1;
});
}
else if (sortBy === "") {