mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-11-07 22:45:46 +01:00
chore: eslint prefer-arrow-callback
This commit is contained in:
committed by
Julian Lam
parent
707b55b6a5
commit
b56d9e12b5
@@ -34,15 +34,13 @@ pagination.create = function (currentPage, pageCount, queryObj) {
|
||||
pagesToShow.push(startPage + i);
|
||||
}
|
||||
|
||||
pagesToShow = _.uniq(pagesToShow).filter(page => page > 0 && page <= pageCount).sort(function (a, b) {
|
||||
return a - b;
|
||||
});
|
||||
pagesToShow = _.uniq(pagesToShow).filter(page => page > 0 && page <= pageCount).sort((a, b) => a - b);
|
||||
|
||||
queryObj = { ...(queryObj || {}) };
|
||||
|
||||
delete queryObj._;
|
||||
|
||||
var pages = pagesToShow.map(function (page) {
|
||||
var pages = pagesToShow.map((page) => {
|
||||
queryObj.page = page;
|
||||
return { page: page, active: page === currentPage, qs: qs.stringify(queryObj) };
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user