Skip to content

Commit c580a52

Browse files
committed
Ajax: remove event dependency from the ajax module
Ref 4e7f34f
1 parent 07afc28 commit c580a52

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

src/ajax/xhr.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,9 @@ var xhrId = 0,
3232

3333
// Support: IE<10
3434
// Open requests must be manually aborted on unload (#5280)
35-
if ( window.ActiveXObject ) {
36-
jQuery( window ).on( "unload", function() {
35+
// See https://support.microsoft.com/kb/2856746 for more info
36+
if ( window.attachEvent ) {
37+
window.attachEvent( "onunload", function() {
3738
for ( var key in xhrCallbacks ) {
3839
xhrCallbacks[ key ]( undefined, true );
3940
}

0 commit comments

Comments
 (0)