void (@NotNull PsiMethodCallExpression call) { PsiExpression container = null; if (ARRAY_METHODS.test(call)) { container = ArrayUtil.getFirstElement(call.getArgumentList().getExpressions()); } else if (COLLECTION_METHODS.test(call) || MAP_METHODS.test(call)) { container = call.getMethodExpression().getQualifierExpression(); if ("iterator".equals(call.getMethodExpression().getReferenceName()) && COLLECTIONS_EMPTY.matches(container)) { return; } } container = PsiUtil.skipParenthesizedExprDown(container); if (container != null) { String msg = getProblemMessage(container); if (msg == null) return; ModCommandAction fix = null; if (ExpressionUtils.isVoidContext(call)) { fix = new DeleteElementFix(call, InspectionGadgetsBundle.message("remove.call.fix.family.name")); } holder.problem(container, msg).maybeFix(fix).fix(getFindCauseFix(container)).register(); } }