Skip to content

When sorting by custom key put untagged archives at the back #1299

@psilabs-dev

Description

@psilabs-dev

When displaying pages of results as a result of calling the search API with a custom sort key (e.g. "source") in descending order, LRR will present untagged archives first, then followed by tagged archives correctly sorted by "source" in descending order. This is because in sort_results the sort values of untagged archives are automatically "zzzz".

I think that whenever sorting is called on a custom key, untagged archives should always be put to the back, because when a user is sorting by a key they're already expecting archives to have the key. Sorting by "source" in descending order has relevance in the context of many sites whose ID generation is increment-based.

A branch on this is in progress. (I don't know how long this will take)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions