simplify null check

This commit is contained in:
Babbaj 2023-06-22 08:30:25 -04:00
parent 47dc0f9b94
commit 535fd17a42
No known key found for this signature in database
GPG Key ID: 0D0F363408CD842A
1 changed files with 4 additions and 6 deletions

View File

@ -123,13 +123,11 @@ public final class ElytraBehavior extends Behavior implements IElytraBehavior, H
})
.whenComplete((result, ex) -> {
this.recalculating = false;
if (ex != null) {
if (ex instanceof PathCalculationException) {
logDirect("Failed to compute path to destination");
} else {
} else if (ex != null) {
logUnhandledException(ex);
}
}
});
}