-
Notifications
You must be signed in to change notification settings - Fork 407
Conversation
//to handle async if it is being used with any other library or windows.XMLHttpRequest.prototype with other library's. This will solve the issue related to Error: More tasks executed then were scheduled. in few cases we are getting undefined.. if(args[2]===undefined) args[2]=true;
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed, please reply here (e.g.
|
1 similar comment
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project. Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA). 📝 Please visit https://cla.developers.google.com/ to sign. Once you've signed, please reply here (e.g.
|
I signed it
…On Fri, Dec 9, 2016 at 11:22 PM, googlebot ***@***.***> wrote:
Thanks for your pull request. It looks like this may be your first
contribution to a Google open source project. Before we can look at your
pull request, you'll need to sign a Contributor License Agreement (CLA).
📝 *Please visit https://cla.developers.google.com/
<https://cla.developers.google.com/> to sign.*
Once you've signed, please reply here (e.g. I signed it!) and we'll
verify. Thanks.
------------------------------
- If you've already signed a CLA, it's possible we don't have your
GitHub username or you're using a different email address. Check your
existing CLA data <https://cla.developers.google.com/clas> and verify
that your email is set on your git commits
<https://help.github.com/articles/setting-your-email-in-git/>.
- If you signed the CLA as a corporation, please let us know the
company's name.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#534 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AQVy9K4eKMNBz653ckEH3ee5gmDBp2Imks5rGZVpgaJpZM4LJMVP>
.
|
CLAs look good, thanks! |
1 similar comment
CLAs look good, thanks! |
@@ -1570,6 +1570,9 @@ function patchXHR(window) { | |||
return abortNative.apply(data.target, data.args); | |||
} | |||
var openNative = patchMethod(window.XMLHttpRequest.prototype, 'open', function () { return function (self, args) { | |||
//to handle async if it is being used with any other library or windows.XMLHttpRequest.prototype with other library's | |||
if(args[2]===undefined) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you provide a sample code or repo to describe the error scenario ?
If the args[2] is undefined, the original code
self[XHR_SYNC] = args[2] == false;
will return false, that means this request will be an async call, I think the original code is correct behavior, your code is not correct to me. because open(url, options, async[options]), by default the async will be true.
about the "More task than scheduled " error, maybe you can check my PR #529 to check whether it fix your issue or not.
And BTW you can't update dist/zone.js directly, you should update lib/browser/browser.ts in this case.
I am sorry, but I can't accept any code without tests demonstrating the issue. It looks like there has been no work on this PR for 9 days, will close. Please open new PR when tests are added. |
//to handle async if it is being used with any other library or windows.XMLHttpRequest.prototype with other library's. This will solve the issue related to Error: More tasks executed then were scheduled. in few cases we are getting undefined..
if(args[2]===undefined)
args[2]=true;