PsiElement (PsiElement expression, PyExpression newExpression, IntroduceOperation operation) { if (operation.getInitPlace() != InitPlace.SAME_METHOD) { return PyReplaceExpressionUtil.replaceExpression(expression, newExpression); } return super.replaceExpression(expression, newExpression, operation); }