From 4b972b0992308047d7af8a90dcc7066b582f1402 Mon Sep 17 00:00:00 2001 From: Sam Matthews <75203773+TheLidlMan@users.noreply.github.com> Date: Tue, 4 Nov 2025 17:15:21 +0000 Subject: [PATCH] feat: Add 'Latest Episode Air Date' sort option for TV show libraries - Add conditional sort option for TV show libraries that sorts by the most recent episode's original air date - Uses 'episode.originallyAvailableAt' field to track when the latest episode aired - Only appears for TV show libraries, not movies or other media types - Defaults to descending order to show recently aired episodes first - Perfect for tracking seasonal anime/shows with new episodes Fixes #31 --- lib/client/plex_client.dart | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/client/plex_client.dart b/lib/client/plex_client.dart index e72acfca..eeec95d7 100644 --- a/lib/client/plex_client.dart +++ b/lib/client/plex_client.dart @@ -796,7 +796,7 @@ class PlexClient { return fallbackSorts; } catch (e) { appLogger.e('Failed to get library sorts: $e'); - // Return minimal fallback sort options on error + // Return fallback sort options on error return [ PlexSort(key: 'titleSort', title: 'Title', defaultDirection: 'asc'), PlexSort(