Skip to content

Commit

Permalink
fix(Spoof Player Parameter): Playback issues appears when opening a Y…
Browse files Browse the repository at this point in the history
  • Loading branch information
YT-Advanced committed Mar 4, 2024
1 parent 1aff64d commit 754c94f
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public static String spoofParameter(@NonNull String videoId, @Nullable String pa
try {
LogHelper.printDebug(() -> "Original player parameter value: " + parameters);

if (!spoofParameter) {
if (parameters == null || !spoofParameter) {
return parameters;
}

Expand All @@ -103,7 +103,7 @@ public static String spoofParameter(@NonNull String videoId, @Nullable String pa

// Clip's player parameters contain important information such as where the video starts, where it ends, and whether it loops.
// Clips are 60 seconds or less in length, so no spoofing.
if (useOriginalStoryboardRenderer = parameters.length() > 150 || containsAny(parameters, CLIPS_PARAMETERS)) {
if (useOriginalStoryboardRenderer = parameters.length() > 150 || parameters.startsWith(CLIPS_PARAMETERS)) {
return parameters;
}

Expand Down

0 comments on commit 754c94f

Please sign in to comment.