Backport pull request #16539 from jellyfin/release-10.11.z

Fix subtitle saving

Original-merge: f51c63e244

Merged-by: nielsvanvelzen <nielsvanvelzen@users.noreply.github.com>

Backported-by: Bond_009 <bond.009@outlook.com>
This commit is contained in:
MBR-0001
2026-04-06 05:19:32 -04:00
committed by Bond_009
parent cf9b8161ef
commit 142ba42883

View File

@@ -221,6 +221,11 @@ namespace MediaBrowser.Providers.Subtitles
private async Task TrySaveToFiles(Stream stream, List<string> savePaths, Video video, string extension)
{
if (!_allowedSubtitleFormats.Contains(extension, StringComparison.OrdinalIgnoreCase))
{
throw new ArgumentException($"Invalid subtitle format: {extension}");
}
List<Exception>? exs = null;
foreach (var savePath in savePaths)