Commit 2434d4e6 by jaewan Committed by marcbaechinger

Remove unnecessary @Nullable in exception message

PiperOrigin-RevId: 367204382
parent c455bad8
...@@ -25,6 +25,7 @@ import androidx.annotation.Nullable; ...@@ -25,6 +25,7 @@ import androidx.annotation.Nullable;
import com.google.android.exoplayer2.C.FormatSupport; import com.google.android.exoplayer2.C.FormatSupport;
import com.google.android.exoplayer2.source.MediaPeriodId; import com.google.android.exoplayer2.source.MediaPeriodId;
import com.google.android.exoplayer2.util.Assertions; import com.google.android.exoplayer2.util.Assertions;
import com.google.android.exoplayer2.util.Util;
import java.io.IOException; import java.io.IOException;
import java.lang.annotation.Documented; import java.lang.annotation.Documented;
import java.lang.annotation.Retention; import java.lang.annotation.Retention;
...@@ -269,7 +270,7 @@ public final class ExoPlaybackException extends Exception implements Bundleable ...@@ -269,7 +270,7 @@ public final class ExoPlaybackException extends Exception implements Bundleable
} }
private ExoPlaybackException( private ExoPlaybackException(
@Nullable String message, String message,
@Nullable Throwable cause, @Nullable Throwable cause,
@Type int type, @Type int type,
@Nullable String rendererName, @Nullable String rendererName,
...@@ -331,7 +332,7 @@ public final class ExoPlaybackException extends Exception implements Bundleable ...@@ -331,7 +332,7 @@ public final class ExoPlaybackException extends Exception implements Bundleable
@CheckResult @CheckResult
/* package */ ExoPlaybackException copyWithMediaPeriodId(@Nullable MediaPeriodId mediaPeriodId) { /* package */ ExoPlaybackException copyWithMediaPeriodId(@Nullable MediaPeriodId mediaPeriodId) {
return new ExoPlaybackException( return new ExoPlaybackException(
getMessage(), Util.castNonNull(getMessage()),
cause, cause,
type, type,
rendererName, rendererName,
...@@ -343,7 +344,6 @@ public final class ExoPlaybackException extends Exception implements Bundleable ...@@ -343,7 +344,6 @@ public final class ExoPlaybackException extends Exception implements Bundleable
isRecoverable); isRecoverable);
} }
@Nullable
private static String deriveMessage( private static String deriveMessage(
@Type int type, @Type int type,
@Nullable String customMessage, @Nullable String customMessage,
...@@ -351,7 +351,7 @@ public final class ExoPlaybackException extends Exception implements Bundleable ...@@ -351,7 +351,7 @@ public final class ExoPlaybackException extends Exception implements Bundleable
int rendererIndex, int rendererIndex,
@Nullable Format rendererFormat, @Nullable Format rendererFormat,
@FormatSupport int rendererFormatSupport) { @FormatSupport int rendererFormatSupport) {
@Nullable String message; String message;
switch (type) { switch (type) {
case TYPE_SOURCE: case TYPE_SOURCE:
message = "Source error"; message = "Source error";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment