mirror of
https://github.com/jellyfin/jellyfin.git
synced 2025-12-16 22:13:06 +03:00
Updated based on review feedback
This commit is contained in:
@@ -1348,7 +1348,7 @@ namespace Jellyfin.Api.Controllers
|
||||
|
||||
var mapArgs = state.IsOutputVideo ? _encodingHelper.GetMapArgs(state) : string.Empty;
|
||||
|
||||
var directory = Path.GetDirectoryName(outputPath) ?? throw new ResourceNotFoundException(nameof(outputPath));
|
||||
var directory = Path.GetDirectoryName(outputPath) ?? throw new ArgumentException($"Provided path ({outputPath}) is not valid.", nameof(outputPath));
|
||||
|
||||
var outputTsArg = Path.Combine(directory, Path.GetFileNameWithoutExtension(outputPath)) + "%d" + GetSegmentFileExtension(state.Request.SegmentContainer);
|
||||
|
||||
@@ -1568,7 +1568,7 @@ namespace Jellyfin.Api.Controllers
|
||||
|
||||
private string GetSegmentPath(StreamState state, string playlist, int index)
|
||||
{
|
||||
var folder = Path.GetDirectoryName(playlist) ?? throw new ResourceNotFoundException(nameof(playlist));
|
||||
var folder = Path.GetDirectoryName(playlist) ?? throw new ArgumentException($"Provided path ({playlist}) is not valid.", nameof(playlist));
|
||||
var filename = Path.GetFileNameWithoutExtension(playlist);
|
||||
|
||||
return Path.Combine(folder, filename + index.ToString(CultureInfo.InvariantCulture) + GetSegmentFileExtension(state.Request.SegmentContainer));
|
||||
|
||||
Reference in New Issue
Block a user