PsiElement (PsiMethodCallExpression orElseGetCall) { final PsiLambdaExpression lambda = tryCast(skipParenthesizedExprDown(orElseGetCall.getArgumentList().getExpressions()[0]), PsiLambdaExpression.class); final PsiExpression thrownException = getThrownException(lambda); if (thrownException == null) return null; final PsiElement body = lambda.getBody(); assert body != null; ExpressionUtils.bindCallTo(orElseGetCall, "orElseThrow"); new CommentTracker().replaceAndRestoreComments(body, thrownException); LambdaCanBeMethodReferenceInspection.replaceLambdaWithMethodReference(lambda); return orElseGetCall; }