refactor: remove superseded code paths

This commit is contained in:
edde746
2026-07-12 08:42:19 +02:00
parent dca51a752a
commit bc55aea701
11 changed files with 14 additions and 365 deletions
@@ -28,7 +28,6 @@ mixin _PlexLiveTvClientMethods on MediaServerCacheMixin {
Map<String, dynamic>? _getMediaContainer(MediaServerResponse response);
PlexMetadataDto _createTaggedMetadata(Map<String, dynamic> json);
List<PlexMetadataDto> _extractMetadataList(MediaServerResponse response);
Future<List<T>> _wrapListApiCall<T>(
Future<MediaServerResponse> Function() apiCall,
@@ -1061,15 +1060,6 @@ mixin _PlexLiveTvClientMethods on MediaServerCacheMixin {
return '${config.baseUrl}$streamPath'.withPlexToken(config.token);
}
/// Get active live TV sessions
Future<List<PlexMetadataDto>> _getLiveTvSessions() {
return _wrapListApiCall<PlexMetadataDto>(
() => _http.get('/livetv/sessions'),
_extractMetadataList,
'Failed to get live TV sessions',
);
}
Future<List<LiveTvSession>> getLiveTvSessionsDetailed() async {
final response = await _getWithFailover('/livetv/sessions');
return _extractContainerList(response, const [
@@ -1153,12 +1143,6 @@ mixin _PlexLiveTvClientMethods on MediaServerCacheMixin {
}
}
/// Plex-specific: live TV sessions (active recordings/playback).
Future<List<MediaItem>> fetchLiveTvSessions() async {
final raw = await _getLiveTvSessions();
return raw.map((m) => PlexMappers.mediaItem(m)).toList();
}
@override
LiveTvSupport get liveTv => _PlexLiveTvSupport(this as PlexClient);
}