Merge pull request #617

v1.7.0 hotfix
This commit is contained in:
Kraiem Taha Yassine 2022-07-15 17:52:28 +02:00 committed by GitHub
commit 5bdbcd2b36
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -160,7 +160,7 @@ const sortPaginate = function (list, filters) {
list.sort((a, b) => {
const tA = getValue(a, "timestamp");
const tB = getValue(b, "timestamp");
return tA > tB ? 1 : tA < tB ? -1 : 0;
return tA < tB ? 1 : tA > tB ? -1 : 0;
});
if (filters.sort.order) {
list.reverse();