Code cleanup.

This commit is contained in:
Mike Cao 2023-08-18 21:52:59 -07:00
parent 21cdb06571
commit 7d5a24044a
10 changed files with 34 additions and 43 deletions

View file

@ -185,9 +185,7 @@ function getPageFilters(filters: SearchFilter<any>): [
orderBy: string;
},
] {
const pageSize = filters?.pageSize || 10;
const page = filters?.page || 1;
const orderBy = filters?.orderBy;
const { pageSize = 10, page = 1, orderBy } = filters || {};
return [
{