| Index: pkg/analysis_server/lib/src/services/correction/util.dart
|
| diff --git a/pkg/analysis_server/lib/src/services/correction/util.dart b/pkg/analysis_server/lib/src/services/correction/util.dart
|
| index 33a31052474bfd976e39df83f3b2b15cfc876b56..ef836c1b99824a46c989b4fd9ad18bac2113648d 100644
|
| --- a/pkg/analysis_server/lib/src/services/correction/util.dart
|
| +++ b/pkg/analysis_server/lib/src/services/correction/util.dart
|
| @@ -396,17 +396,14 @@ AstNode getNearestCommonAncestor(List<AstNode> nodes) {
|
| */
|
| Expression getNodeQualifier(SimpleIdentifier node) {
|
| AstNode parent = node.parent;
|
| - if (parent is PropertyAccess) {
|
| - PropertyAccess propertyAccess = parent;
|
| - if (identical(propertyAccess.propertyName, node)) {
|
| - return propertyAccess.target;
|
| - }
|
| + if (parent is MethodInvocation && identical(parent.methodName, node)) {
|
| + return parent.target;
|
| }
|
| - if (parent is PrefixedIdentifier) {
|
| - PrefixedIdentifier prefixed = parent;
|
| - if (identical(prefixed.identifier, node)) {
|
| - return prefixed.prefix;
|
| - }
|
| + if (parent is PropertyAccess && identical(parent.propertyName, node)) {
|
| + return parent.target;
|
| + }
|
| + if (parent is PrefixedIdentifier && identical(parent.identifier, node)) {
|
| + return parent.prefix;
|
| }
|
| return null;
|
| }
|
|
|