Skip to content

Commit

Permalink
Remove Chrome bug workaround from a-asset-item as it's no longer need…
Browse files Browse the repository at this point in the history
…ed (#5335)

Co-authored-by: Noeri Huisman <mrxz@users.noreply.github.com>
  • Loading branch information
mrxz and mrxz authored Jul 13, 2023
1 parent 7d5294b commit aacacad
Showing 1 changed file with 1 addition and 9 deletions.
10 changes: 1 addition & 9 deletions src/core/a-assets.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,15 +115,7 @@ class AAssetItem extends ANode {
this.getAttribute('response-type') || inferResponseType(src));
fileLoader.load(src, function handleOnLoad (response) {
self.data = response;
/*
Workaround for a Chrome bug. If another XHR is sent to the same url before the
previous one closes, the second request never finishes.
setTimeout finishes the first request and lets the logic triggered by load open
subsequent requests.
setTimeout can be removed once the fix for the bug below ships:
https://bugs.chromium.org/p/chromium/issues/detail?id=633696&q=component%3ABlink%3ENetwork%3EXHR%20&colspec=ID%20Pri%20M%20Stars%20ReleaseBlock%20Component%20Status%20Owner%20Summary%20OS%20Modified
*/
setTimeout(function load () { ANode.prototype.load.call(self); });
ANode.prototype.load.call(self);
}, function handleOnProgress (xhr) {
self.emit('progress', {
loadedBytes: xhr.loaded,
Expand Down

0 comments on commit aacacad

Please sign in to comment.