Fix PMD warning

This commit is contained in:
Clément Fournier
2024-05-16 13:52:29 +02:00
parent eb17c9aab7
commit ed18c9d746

View File

@ -176,10 +176,7 @@ public class UnnecessaryBoxingRule extends AbstractJavaRulechainRule {
private boolean isObjectConversionNecessary(ASTExpression e) {
JavaNode parent = e.getParent();
if (e.getIndexInParent() == 0) {
return parent instanceof QualifiableExpression;
}
return false;
return e.getIndexInParent() == 0 && parent instanceof QualifiableExpression;
}