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

Unified Diff: lib/dom/src/_XMLHttpRequestUtils.dart

Issue 10831314: Don't auto-send credentials on XHR.get (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Fix test status for dart2js Created 8 years, 4 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: lib/dom/src/_XMLHttpRequestUtils.dart
diff --git a/lib/dom/src/_XMLHttpRequestUtils.dart b/lib/dom/src/_XMLHttpRequestUtils.dart
index 0875dd2d23a31f8ddd132a8fbf39c896c876ef26..17c820df69981fc49be0a3b55f447bfa5701f5aa 100644
--- a/lib/dom/src/_XMLHttpRequestUtils.dart
+++ b/lib/dom/src/_XMLHttpRequestUtils.dart
@@ -6,13 +6,12 @@ class _XMLHttpRequestUtils {
// Helper for factory XMLHttpRequest.get
static XMLHttpRequest get(String url,
- onSuccess(XMLHttpRequest request)) {
+ onSuccess(XMLHttpRequest request),
+ bool withCredentials) {
final request = new XMLHttpRequest();
request.open('GET', url, true);
- // TODO(terry): Validate after client login added if necessary to forward
- // cookies to server.
- request.withCredentials = true;
+ request.withCredentials = withCredentials;
// Status 0 is for local XHR request.
request.on.readyStateChange.add((e) {

Powered by Google App Engine
This is Rietveld 408576698