Browse Source

Apply suggestions from code review

Co-authored-by: Claus Vium <cvium@users.noreply.github.com>
Nyanmisaka 3 years ago
parent
commit
d4f09c6c9b
1 changed files with 1 additions and 1 deletions
  1. 1 1
      MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs

+ 1 - 1
MediaBrowser.Controller/MediaEncoding/EncodingHelper.cs

@@ -3575,7 +3575,7 @@ namespace MediaBrowser.Controller.MediaEncoding
                     && IsVppTonemappingSupported(state, encodingOptions))
                     && IsVppTonemappingSupported(state, encodingOptions))
                 {
                 {
                     var outputVideoCodec = GetVideoEncoder(state, encodingOptions) ?? string.Empty;
                     var outputVideoCodec = GetVideoEncoder(state, encodingOptions) ?? string.Empty;
-                    var isQsvEncoder = outputVideoCodec.IndexOf("qsv", StringComparison.OrdinalIgnoreCase) != -1;
+                    var isQsvEncoder = outputVideoCodec.Contains("qsv", StringComparison.OrdinalIgnoreCase);
                     if (isQsvEncoder)
                     if (isQsvEncoder)
                     {
                     {
                         // Since tonemap_vaapi only support HEVC for now, no need to check the codec again.
                         // Since tonemap_vaapi only support HEVC for now, no need to check the codec again.