Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(529)

Unified Diff: pkg/analysis_server/lib/src/domain_analysis.dart

Issue 417433003: Send responses for any pending 'analysis.getErrors' requests during context removal. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 6 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: pkg/analysis_server/lib/src/domain_analysis.dart
diff --git a/pkg/analysis_server/lib/src/domain_analysis.dart b/pkg/analysis_server/lib/src/domain_analysis.dart
index ef166c85819f842d897e30202127a0690a6f139c..de436a98b0dd5324889d0cb00c4acb05c69ff075 100644
--- a/pkg/analysis_server/lib/src/domain_analysis.dart
+++ b/pkg/analysis_server/lib/src/domain_analysis.dart
@@ -47,7 +47,11 @@ class AnalysisDomainHandler implements RequestHandler {
}).toList());
}
server.sendResponse(response);
- });
+ }).catchError((message) {
+ Response response = new Response.getErrorsError(request, message);
+ response.setResult(ERRORS, []);
Paul Berry 2014/07/23 15:06:51 In this case wouldn't it be more appropriate for t
scheglov 2014/07/24 16:54:04 The "errors" field in response is not optional.
+ server.sendResponse(response);
+ }, test: (e) => e is String);
Paul Berry 2014/07/23 15:06:51 This means that in the unlikely event that e is no
scheglov 2014/07/24 16:54:04 Done.
// delay response
return Response.DELAYED_RESPONSE;
}

Powered by Google App Engine
This is Rietveld 408576698