Remove useless else

The if-block ends with a return.
This commit is contained in:
Romain Vimont 2019-06-14 10:15:10 +02:00
parent fe758e6e15
commit 4940746bcb

View file

@ -82,9 +82,8 @@ public final class SurfaceControl {
// <https://github.com/Genymobile/scrcpy/issues/586>
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.Q) {
return (IBinder) CLASS.getMethod("getBuiltInDisplay", int.class).invoke(null, builtInDisplayId);
} else {
return (IBinder) CLASS.getMethod("getPhysicalDisplayToken", long.class).invoke(null, builtInDisplayId);
}
return (IBinder) CLASS.getMethod("getPhysicalDisplayToken", long.class).invoke(null, builtInDisplayId);
} catch (Exception e) {
throw new AssertionError(e);
}