Index: pkg/analysis_server/lib/src/services/correction/assist_internal.dart |
diff --git a/pkg/analysis_server/lib/src/services/correction/assist_internal.dart b/pkg/analysis_server/lib/src/services/correction/assist_internal.dart |
index abad641b62f21daa9145920773b43b2425436f92..c6f1c020ad004e82b583dc7fb08559ea026b9f82 100644 |
--- a/pkg/analysis_server/lib/src/services/correction/assist_internal.dart |
+++ b/pkg/analysis_server/lib/src/services/correction/assist_internal.dart |
@@ -1251,6 +1251,10 @@ class AssistProcessor { |
// prepare outer "if" statement |
AstNode parent = targetIfStatement.parent; |
if (parent is Block) { |
+ if ((parent as Block).statements.length != 1) { |
+ _coverageMarker(); |
+ return; |
+ } |
parent = parent.parent; |
} |
if (parent is! IfStatement) { |