diff --git a/python/src/com/jetbrains/python/inspections/quickfix/AddMethodQuickFix.java b/python/src/com/jetbrains/python/inspections/quickfix/AddMethodQuickFix.java index f2246b11e999..30d99103b887 100644 --- a/python/src/com/jetbrains/python/inspections/quickfix/AddMethodQuickFix.java +++ b/python/src/com/jetbrains/python/inspections/quickfix/AddMethodQuickFix.java @@ -67,9 +67,8 @@ public class AddMethodQuickFix implements LocalQuickFix { public void applyFix(@NotNull Project project, @NotNull ProblemDescriptor descriptor) { try { - // descriptor points to the unresolved identifier // there can be no name clash, else the name would have resolved, and it hasn't. - PsiElement problem_elt = descriptor.getPsiElement().getParent(); // id -> ref expr + PsiElement problem_elt = descriptor.getPsiElement(); PyClass cls = myQualifierType.getPyClass(); boolean call_by_class = myQualifierType.isDefinition(); String item_name = myIdentifier;