Merge pull request #6083 from Bond-009/nullable4

Enable nullable reference types for Emby.Server.Implementations
This commit is contained in:
Bond-009
2021-05-21 13:05:03 +02:00
committed by GitHub
151 changed files with 300 additions and 99 deletions

View File

@@ -379,7 +379,9 @@ namespace Jellyfin.Api.Helpers
/// <param name="outputFilePath">The output file path.</param>
private void DeleteHlsPartialStreamFiles(string outputFilePath)
{
var directory = Path.GetDirectoryName(outputFilePath);
var directory = Path.GetDirectoryName(outputFilePath)
?? throw new ArgumentException("Path can't be a root directory.", nameof(outputFilePath));
var name = Path.GetFileNameWithoutExtension(outputFilePath);
var filesToDelete = _fileSystem.GetFilePaths(directory)