Przeglądaj źródła

Minor code formatting (cvium)

Nick 1 rok temu
rodzic
commit
65b269c151
1 zmienionych plików z 3 dodań i 3 usunięć
  1. 3 3
      Jellyfin.Api/Helpers/DynamicHlsHelper.cs

+ 3 - 3
Jellyfin.Api/Helpers/DynamicHlsHelper.cs

@@ -307,7 +307,7 @@ public class DynamicHlsHelper
             AppendPlaylist(builder, state, variantUrl, newBitrate, subtitleGroup);
         }
 
-        if (!isLiveStream && (state.VideoRequest?.EnableTrickplay).GetValueOrDefault(false))
+        if (!isLiveStream && (state.VideoRequest?.EnableTrickplay ?? false))
         {
             var sourceId = Guid.Parse(state.Request.MediaSourceId);
             var trickplayResolutions = await _trickplayManager.GetTrickplayResolutions(sourceId).ConfigureAwait(false);
@@ -565,7 +565,7 @@ public class DynamicHlsHelper
                 state.Request.MediaSourceId,
                 user.GetToken());
 
-            var line = string.Format(
+            builder.AppendFormat(
                 CultureInfo.InvariantCulture,
                 playlistFormat,
                 trickplayInfo.Bandwidth.ToString(CultureInfo.InvariantCulture),
@@ -573,7 +573,7 @@ public class DynamicHlsHelper
                 trickplayInfo.Height.ToString(CultureInfo.InvariantCulture),
                 url);
 
-            builder.AppendLine(line);
+            builder.AppendLine();
         }
     }