PsiMethodCallExpression (PsiMethodCallExpression expression) { final PsiReferenceExpression methodExpression = expression.getMethodExpression(); final PsiExpression qualifierExpression = PsiUtil.skipParenthesizedExprDown(methodExpression.getQualifierExpression()); if (qualifierExpression instanceof PsiMethodCallExpression methodCallExpression) { return getRootMethodCallExpression(methodCallExpression); } return expression; }