diff --git a/java/java-impl/src/com/intellij/codeInspection/OptionalIsPresentInspection.java b/java/java-impl/src/com/intellij/codeInspection/OptionalIsPresentInspection.java index e16cbdbf50a6..733a8454c00e 100644 --- a/java/java-impl/src/com/intellij/codeInspection/OptionalIsPresentInspection.java +++ b/java/java-impl/src/com/intellij/codeInspection/OptionalIsPresentInspection.java @@ -287,7 +287,6 @@ public class OptionalIsPresentInspection extends AbstractBaseJavaLocalInspection else { return; } - if (myScenario.getProblemType(optionalRef, thenElement, elseElement) == ProblemType.NONE) return; PsiElementFactory factory = JavaPsiFacade.getElementFactory(project); CommentTracker ct = new CommentTracker(); String replacementText = myScenario.generateReplacement(factory, ct, optionalRef, thenElement, elseElement);