Skip to main content

## default_listing_sort

# Function default_listing_sort

Source

    pub fn default_listing_sort(
        parent_kind: Option<MediaKind>,
    ) -> Option<(&'static str, &'static str)>

Expand description

The order a container’s children take when the caller asked for none.

Ordering by name is right for a library, a series or an album, and wrong for a channel folder: plugin channels — a podcast feed, say — carry a release date and are read newest-first, and Jellypod additionally prefixes played episodes with “[Played]”, so a name sort clumped every heard episode at the top of the list. Returns `None` when no container kind was given, so callers that deliberately rely on the server’s own order keep it.

This mapping is domain vocabulary and lives here rather than in the frontend, for the reason in docs/specs/scoped-search-boundary.md.

TRACES: UR-007 | DR-257 | UT-229