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

Unified Diff: pkg/oauth2/lib/src/handle_access_token_response.dart

Issue 11308110: Add TODOs about narrowing JSON catch clauses to the OAuth2 package. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 1 month 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
« no previous file with comments | « pkg/oauth2/lib/src/credentials.dart ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: pkg/oauth2/lib/src/handle_access_token_response.dart
diff --git a/pkg/oauth2/lib/src/handle_access_token_response.dart b/pkg/oauth2/lib/src/handle_access_token_response.dart
index af94f911f5d34027d8068aaba14f13204484c9b4..cb08d8fd2e3a29b83261838ddc47cb7fd8b03597 100644
--- a/pkg/oauth2/lib/src/handle_access_token_response.dart
+++ b/pkg/oauth2/lib/src/handle_access_token_response.dart
@@ -42,6 +42,7 @@ Credentials handleAccessTokenResponse(
try {
parameters = JSON.parse(response.body);
} catch (e) {
+ // TODO(nweiz): narrow this catch clause once issue 6775 is fixed.
validate(false, 'invalid JSON');
}
@@ -111,6 +112,7 @@ void _handleErrorResponse(http.Response response, Uri tokenEndpoint) {
try {
parameters = JSON.parse(response.body);
} catch (e) {
+ // TODO(nweiz): narrow this catch clause once issue 6775 is fixed.
validate(false, 'invalid JSON');
}
« no previous file with comments | « pkg/oauth2/lib/src/credentials.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698