mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-11-17 20:20:44 +00:00
Fix Chrome warning when using synchronous XHR requests
This commit is contained in:
1 parent
65b3e9f8c1
commit
2ab9186259
1 file changed
+3
-2
@@ -246,7 +246,8 @@ CFHTTPRequest.prototype.open = function(/*String*/ aMethod, /*String*/ aURL, /*B
|
||||
this._user = aUser;
|
||||
this._password = aPassword;
|
||||
retval = this._nativeRequest.open(aMethod, aURL, isAsynchronous, aUser, aPassword);
|
||||
this._nativeRequest.withCredentials = this._withCredentials;
|
||||
if (this._async)
|
||||
this._nativeRequest.withCredentials = this._withCredentials;
|
||||
|
||||
return retval;
|
||||
};
|
||||
@@ -304,7 +305,7 @@ CFHTTPRequest.prototype.removeEventListener = function(/*String*/ anEventName, /
|
||||
CFHTTPRequest.prototype.setWithCredentials = function(/*Boolean*/ willSendWithCredentials)
|
||||
{
|
||||
this._withCredentials = willSendWithCredentials
|
||||
if (this._isOpen)
|
||||
if (this._isOpen && this._async)
|
||||
this._nativeRequest.withCredentials = willSendWithCredentials;
|
||||
};
|
||||
|
||||
|
||||
Reference in new issue
Block a user