Merge conditionals - no need for separate if block

This commit is contained in:
Sebb 2019-09-05 17:12:09 +01:00
parent 5e5e61fb53
commit 970d794e82
1 changed files with 1 additions and 2 deletions

View File

@ -552,8 +552,7 @@ public class Functions {
public static RuntimeException rethrow(Throwable pThrowable) {
if (pThrowable == null) {
throw new NullPointerException("The Throwable must not be null.");
}
if (pThrowable instanceof RuntimeException) {
} else if (pThrowable instanceof RuntimeException) {
throw (RuntimeException) pThrowable;
} else if (pThrowable instanceof Error) {
throw (Error) pThrowable;