mirror of
https://github.com/omnivore-app/omnivore.git
synced 2026-03-11 08:54:26 +00:00
if only rank orders are present, add saved at order
This commit is contained in:
parent
173691048b
commit
accab510a7
1 changed files with 4 additions and 1 deletions
|
|
@ -694,7 +694,10 @@ export const createSearchQueryBuilder = (
|
|||
}
|
||||
|
||||
// default order by saved at descending
|
||||
if (orders.length === 0) {
|
||||
if (
|
||||
orders.length === 0 ||
|
||||
orders.every((order) => order.by.startsWith('rank')) // if only rank orders are present, add saved at order
|
||||
) {
|
||||
orders.push({
|
||||
by: 'library_item.saved_at',
|
||||
order: SortOrder.DESCENDING,
|
||||
|
|
|
|||
Loading…
Reference in a new issue