@NotNull
      @Override
      public ProblemType getProblemType(@NotNull PsiReferenceExpression optionalVariable,
                                        @Nullable PsiElement trueElement,
                                        @Nullable PsiElement falseElement) {
        PsiAssignmentExpression trueAssignment = ExpressionUtils.getAssignment(trueElement);
        PsiAssignmentExpression falseAssignment = ExpressionUtils.getAssignment(falseElement);
        if (trueAssignment == null || falseAssignment == null) return ProblemType.NONE;
        PsiExpression falseVal = falseAssignment.getRExpression();
        PsiExpression trueVal = trueAssignment.getRExpression();
        if (areElementsEquivalent(trueAssignment.getLExpression(), falseAssignment.getLExpression()) &&
            isSimpleOrUnchecked(falseVal)) {
          return getTypeByLambdaCandidate(optionalVariable, trueVal, falseVal);
        }
        return ProblemType.NONE;
      }
@NotNull
      @Override
      public ProblemType getProblemType(@NotNull PsiReferenceExpression optionalVariable,
                                        @Nullable PsiElement trueElement,
                                        @Nullable PsiElement falseElement)