From bcb2a3d5e95a15de9ad41885ab27f68479473f19 Mon Sep 17 00:00:00 2001 From: gnattu Date: Tue, 15 Oct 2024 18:22:39 +0800 Subject: [PATCH 1/3] Don't check remote sources for trickplay --- .../Trickplay/TrickplayManager.cs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs index f6c48498ca..4aa998591e 100644 --- a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs +++ b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs @@ -498,6 +498,11 @@ public class TrickplayManager : ITrickplayManager var trickplayManifest = new Dictionary>(); foreach (var mediaSource in item.GetMediaSources(false)) { + if (mediaSource.IsRemote) + { + continue; + } + var mediaSourceId = Guid.Parse(mediaSource.Id); var trickplayResolutions = await GetTrickplayResolutions(mediaSourceId).ConfigureAwait(false); From 666db81a09e32f4fd8ddb201ff2fddaca0481007 Mon Sep 17 00:00:00 2001 From: gnattu Date: Wed, 16 Oct 2024 17:47:24 +0800 Subject: [PATCH 2/3] Allow invalid id for trickplay Co-authored-by: JPVenson --- Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs index 4aa998591e..25870305e2 100644 --- a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs +++ b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs @@ -498,12 +498,10 @@ public class TrickplayManager : ITrickplayManager var trickplayManifest = new Dictionary>(); foreach (var mediaSource in item.GetMediaSources(false)) { - if (mediaSource.IsRemote) + if (mediaSource.IsRemote || !Guid.TryParse(mediaSource.Id, out var mediaSourceId) { continue; } - - var mediaSourceId = Guid.Parse(mediaSource.Id); var trickplayResolutions = await GetTrickplayResolutions(mediaSourceId).ConfigureAwait(false); if (trickplayResolutions.Count > 0) From 5ac895bef66d53d6cba148d7816b021c0a655380 Mon Sep 17 00:00:00 2001 From: gnattu Date: Wed, 16 Oct 2024 17:50:19 +0800 Subject: [PATCH 3/3] Fix format --- Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs index 25870305e2..cfe385106a 100644 --- a/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs +++ b/Jellyfin.Server.Implementations/Trickplay/TrickplayManager.cs @@ -498,10 +498,11 @@ public class TrickplayManager : ITrickplayManager var trickplayManifest = new Dictionary>(); foreach (var mediaSource in item.GetMediaSources(false)) { - if (mediaSource.IsRemote || !Guid.TryParse(mediaSource.Id, out var mediaSourceId) + if (mediaSource.IsRemote || !Guid.TryParse(mediaSource.Id, out var mediaSourceId)) { continue; } + var trickplayResolutions = await GetTrickplayResolutions(mediaSourceId).ConfigureAwait(false); if (trickplayResolutions.Count > 0)