Update MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs

Co-authored-by: Cody Robibero <cody@robibe.ro>
This commit is contained in:
Isaac Gordezky 2022-02-21 07:54:13 -05:00 committed by GitHub
parent 151ddd400d
commit def8500dd0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1677,7 +1677,8 @@ namespace MediaBrowser.Controller.MediaEncoding
}
// Source and target codecs must match
if (string.IsNullOrEmpty(videoStream.Codec) || (state.SupportedVideoCodecs.Any()
if (string.IsNullOrEmpty(videoStream.Codec)
|| (state.SupportedVideoCodecs.Length != 0
&& !state.SupportedVideoCodecs.Contains(videoStream.Codec, StringComparison.OrdinalIgnoreCase)))
{
return false;