Merge pull request #4575 from crobibero/null-ref

Don't throw null reference if ContentType is null.
This commit is contained in:
Claus Vium 2020-11-25 08:20:57 +01:00 committed by GitHub
commit e86385b74d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -63,7 +63,7 @@ namespace Emby.Server.Implementations.LiveTv.TunerHosts
var extension = "ts";
var requiresRemux = false;
var contentType = response.Content.Headers.ContentType.ToString();
var contentType = response.Content.Headers.ContentType?.ToString() ?? string.Empty;
if (contentType.IndexOf("matroska", StringComparison.OrdinalIgnoreCase) != -1)
{
requiresRemux = true;